[ Index ] |
PHP Cross Reference of MyBB |
[Summary view] [Print] [Text view]
1 <?php 2 /** 3 * MyBB 1.6 4 * Copyright 2010 MyBB Group, All Rights Reserved 5 * 6 * Website: http://mybb.com 7 * License: http://mybb.com/about/license 8 * 9 * $Id: module_meta.php 5620 2011-09-26 18:23:52Z ralgith $ 10 */ 11 12 // Disallow direct access to this file for security reasons 13 if(!defined("IN_MYBB")) 14 { 15 die("Direct initialization of this file is not allowed.<br /><br />Please make sure IN_MYBB is defined."); 16 } 17 18 function style_meta() 19 { 20 global $page, $lang, $plugins; 21 22 $sub_menu = array(); 23 $sub_menu['10'] = array("id" => "themes", "title" => $lang->themes, "link" => "index.php?module=style-themes"); 24 $sub_menu['20'] = array("id" => "templates", "title" => $lang->templates, "link" => "index.php?module=style-templates"); 25 26 $sub_menu = $plugins->run_hooks("admin_style_menu", $sub_menu); 27 28 $page->add_menu_item($lang->templates_and_style, "style", "index.php?module=style", 40, $sub_menu); 29 return true; 30 } 31 32 function style_action_handler($action) 33 { 34 global $page, $lang, $plugins; 35 36 $page->active_module = "style"; 37 38 $actions = array( 39 'templates' => array('active' => 'templates', 'file' => 'templates.php'), 40 'themes' => array('active' => 'themes', 'file' => 'themes.php') 41 ); 42 43 $actions = $plugins->run_hooks("admin_style_action_handler", $actions); 44 45 if(isset($actions[$action])) 46 { 47 $page->active_action = $actions[$action]['active']; 48 return $actions[$action]['file']; 49 } 50 else 51 { 52 $page->active_action = "themes"; 53 return "themes.php"; 54 } 55 } 56 57 function style_admin_permissions() 58 { 59 global $lang, $plugins; 60 61 $admin_permissions = array( 62 "themes" => $lang->can_manage_themes, 63 "templates" => $lang->can_manage_templates, 64 ); 65 66 $admin_permissions = $plugins->run_hooks("admin_style_permissions", $admin_permissions); 67 68 return array("name" => $lang->templates_and_style, "permissions" => $admin_permissions, "disporder" => 40); 69 } 70 ?>
title
Description
Body
title
Description
Body
title
Description
Body
title
Body
Generated: Tue Oct 8 19:19:50 2013 | Cross-referenced by PHPXref 0.7.1 |