Changeset 29206 for trunk/src/wp-admin/includes/plugin.php
- Timestamp:
- 07/17/2014 09:13:53 AM (11 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-admin/includes/plugin.php
r28673 r29206 852 852 function validate_active_plugins() { 853 853 $plugins = get_option( 'active_plugins', array() ); 854 // validate vartype: array854 // Validate vartype: array. 855 855 if ( ! is_array( $plugins ) ) { 856 856 update_option( 'active_plugins', array() ); … … 868 868 $invalid = array(); 869 869 870 // invalid plugins get deactivated870 // Invalid plugins get deactivated. 871 871 foreach ( $plugins as $plugin ) { 872 872 $result = validate_plugin( $plugin ); … … 1120 1120 } 1121 1121 1122 // If the parent doesn't already have a submenu, add a link to the parent 1123 // as the first item in the submenu. If the submenu file is the same as the 1124 // parent file someone is trying to link back to the parent manually. In 1125 // this case, don't automatically add a link back to avoid duplication. 1122 /* 1123 * If the parent doesn't already have a submenu, add a link to the parent 1124 * as the first item in the submenu. If the submenu file is the same as the 1125 * parent file someone is trying to link back to the parent manually. In 1126 * this case, don't automatically add a link back to avoid duplication. 1127 */ 1126 1128 if (!isset( $submenu[$parent_slug] ) && $menu_slug != $parent_slug ) { 1127 1129 foreach ( (array)$menu as $parent_menu ) { … … 1138 1140 1139 1141 $_registered_pages[$hookname] = true; 1140 // backwards-compatibility for plugins using add_management page. See wp-admin/admin.php for redirect from edit.php to tools.php 1142 1143 /* 1144 * Backward-compatibility for plugins using add_management page. 1145 * See wp-admin/admin.php for redirect from edit.php to tools.php 1146 */ 1141 1147 if ( 'tools.php' == $parent_slug ) 1142 1148 $_registered_pages[get_plugin_page_hookname( $menu_slug, 'edit.php')] = true; 1143 1149 1144 // No parent as top level 1150 // No parent as top level. 1145 1151 $_parent_pages[$menu_slug] = $parent_slug; 1146 1152
Note: See TracChangeset
for help on using the changeset viewer.