public/wordpress/wp-content/plugins/h5p/admin/class-h5p-plugin-admin.php
/**
   * Register the administration menu for this plugin into the WordPress Dashboard menu.
   *
   * @since 1.0.0
   */
Register the administration menu for this plugin into the WordPress Dashboard menu.
Register the administration menu for this plugin into the WordPress Dashboard menu .
public function add_plugin_admin_menu() {
    $h5p_content = __('H5P Content', $this->plugin_slug);
    add_menu_page($h5p_content, $h5p_content, 'edit_h5p_contents', $this->plugin_slug, array($this->content, 'display_contents_page'), 'none');
    $all_h5p_content = __('All H5P Content', $this->plugin_slug);
    add_submenu_page($this->plugin_slug, $all_h5p_content, $all_h5p_content, 'edit_h5p_contents', $this->plugin_slug, array($this->content, 'display_contents_page'));
    $add_new = __('Add New', $this->plugin_slug);
    $contents_page = add_submenu_page($this->plugin_slug, $add_new, $add_new, 'edit_h5p_contents', $this->plugin_slug . '_new', array($this->content, 'display_new_content_page'));
    add_action('load-' . $contents_page, array($this->content, 'process_new_content'));
    $libraries = __('Libraries', $this->plugin_slug);
    $libraries_page = add_submenu_page($this->plugin_slug, $libraries, $libraries, 'manage_h5p_libraries', $this->plugin_slug . '_libraries', array($this->library, 'display_libraries_page'));
    add_action('load-' . $libraries_page, array($this->library, 'process_libraries'));
    if (get_option('h5p_track_user', TRUE)) {
      $my_results = __('My Results', $this->plugin_slug);
      add_submenu_page($this->plugin_slug, $my_results, $my_results, 'view_h5p_results', $this->plugin_slug . '_results', array($this, 'display_results_page'));
    }
    add_options_page('H5P Settings', 'H5P', 'manage_options', $this->plugin_slug . '_settings', array($this, 'display_settings_page'));
  }
public function add_plugin_admin_menu ( ) { $ h5p_content = __ ( 'H5P Content' , $ this -> plugin_slug ) ; add_menu_page ( $ h5p_content , $ h5p_content , 'edit_h5p_contents' , $ this -> plugin_slug , array ( $ this -> content , 'display_contents_page' ) , 'none' ) ; $ all_h5p_content = __ ( 'All H5P Content' , $ this -> plugin_slug ) ; add_submenu_page ( $ this -> plugin_slug , $ all_h5p_content , $ all_h5p_content , 'edit_h5p_contents' , $ this -> plugin_slug , array ( $ this -> content , 'display_contents_page' ) ) ; $ add_new = __ ( 'Add New' , $ this -> plugin_slug ) ; $ contents_page = add_submenu_page ( $ this -> plugin_slug , $ add_new , $ add_new , 'edit_h5p_contents' , $ this -> plugin_slug . '_new' , array ( $ this -> content , 'display_new_content_page' ) ) ; add_action ( 'load-' . $ contents_page , array ( $ this -> content , 'process_new_content' ) ) ; $ libraries = __ ( 'Libraries' , $ this -> plugin_slug ) ; $ libraries_page = add_submenu_page ( $ this -> plugin_slug , $ libraries , $ libraries , 'manage_h5p_libraries' , $ this -> plugin_slug . '_libraries' , array ( $ this -> library , 'display_libraries_page' ) ) ; add_action ( 'load-' . $ libraries_page , array ( $ this -> library , 'process_libraries' ) ) ; if ( get_option ( 'h5p_track_user' , TRUE ) ) { $ my_results = __ ( 'My Results' , $ this -> plugin_slug ) ; add_submenu_page ( $ this -> plugin_slug , $ my_results , $ my_results , 'view_h5p_results' , $ this -> plugin_slug . '_results' , array ( $ this , 'display_results_page' ) ) ; } add_options_page ( 'H5P Settings' , 'H5P' , 'manage_options' , $ this -> plugin_slug . '_settings' , array ( $ this , 'display_settings_page' ) ) ; }
Register the administration menu for this plugin into the WordPress Dashboard menu.
Register the administration menu for this plugin into the WordPress Dashboard menu .
// H5P Content pages // Process form data when saving H5Ps. // Process form data when upload H5Ps without content. // Settings page