• Resolved alexandrubau

    (@alexandrubau)


    I want to create a plugin which will have a simple HTML page.
    So, after I active the plugin, I want a new button to appear in the left menu. After the user clicks the button I want to display a static HTML page. How can I achieve this ?
    I’ve searched and haven’t found anything

    Thank you !

Viewing 1 replies (of 1 total)
  • Thread Starter alexandrubau

    (@alexandrubau)

    function oscimp_admin() {
        echo '<p>awesome</p>';
    }
    
    function oscimp_admin_actions() {
    
        $page_title = 'WordPress Extra Post Info';
        $menu_title = 'Extra Post Info';
        $capability = 'manage_options';
        $menu_slug  = 'extra-post-info';
        $function   = 'oscimp_admin';
        $icon_url   = 'dashicons-media-code';
        $position   = 4;
    
        add_menu_page( $page_title,
            $menu_title,
            $capability,
            $menu_slug,
            $function,
            $icon_url,
            $position );
    }
    
    add_action('admin_menu', 'oscimp_admin_actions');
Viewing 1 replies (of 1 total)
  • The topic ‘Create plugin with custom html page’ is closed to new replies.