Support » Plugins » No menu items in administration

  • Resolved Speed_FANat1c



    I am new to wordpress. I am trying to write a plugin and want try to make options in administration.

    I have such code in my file:

    	Plugin Name: OSCommerce Productu rodymas
    	Plugin URI:
    	Description: Pluginas produktu roymui is OScommerce parduotuves
    	Author: Darius
    	Version: 1.0
    	Author URI:
    add_action('admin_menu', 'my_plugin_menu');
    function my_plugin_menu() {
    	add_options_page('My Plugin Options', 'My Plugin', 'manage_options', 'my-unique-identifier', 'my_plugin_options');
    function my_plugin_options() {
    	if (!current_user_can('manage_options'))  {
    		wp_die( __('You do not have sufficient permissions to access this page.') );
    	echo '<div class="wrap">';
    	echo '<p>Here is where the form would go if I actually had options.</p>';
    	echo '</div>';

    But no menu item appear in the administration area. Can you tell why is that?

    Edit: I have simply not activated it, thats why no menu was there 😀

  • The topic ‘No menu items in administration’ is closed to new replies.