LLMS_Admin_Menus::instructor_menu_hack()
Removes edit.php from the admin menu for instructors/asst instructors
Description Description
Note: The post screen is still technically accessible.
Posts will need to be submitted for review as the instructors only actually have the capability of a contributor with regards to posts but this hack will allow instructors to publish new lessons, quizzes, & questions.
Return Return
(void)
Source Source
File: includes/admin/class.llms.admin.menus.php
* @since 3.13.0
* @since 7.0.1 Added filterable early return allowing 3rd parties to modify
* the user roles affected by this hack.
*
* @link https://core.trac.wordpress.org/ticket/22895
* @link https://core.trac.wordpress.org/ticket/16808
*
* @return void
*/
public function instructor_menu_hack() {
/**
* Filters the WP_User roles should receive the instructor admin menu hack.
*
* If you wish to provide explicit access to the `post` post type, to the
* instrutor or instructor's assistant role, the role will need to be
* removed from this array so they can access to the post type edit.php
* screen.
*
* @see LLMS_Admin_Menus::instructor_menu_hack
*
* @since 7.0.1
*
Expand full source code Collapse full source code View on GitHub
Changelog Changelog
| Version | Description |
|---|---|
| 7.0.1 | Added filterable early return allowing 3rd parties to modify the user roles affected by this hack. |
| 3.13.0 | Introduced. |