function wptouch_admin_menu() { $settings = wptouch_get_settings(); if ($settings->put_wptouch_in_appearance_menu) { add_submenu_page('themes.php', __("WPtouch Pro", "wptouch-pro"), __("WPtouch Pro", "wptouch-pro"), 'manage_options', __FILE__, 'wptouch_admin_panel'); } else { // Check to see if another plugin created the BraveNewCode menu if (!defined('WPTOUCH_MENU')) { define('WPTOUCH_MENU', true); // Add the main plugin menu for WPtouch Pro add_menu_page('WPtouch Pro', 'WPtouch Pro', 'manage_options', __FILE__, '', get_wptouch_url() . '/admin/images/wptouch-admin-icon.png'); } add_submenu_page(__FILE__, __("Settings", "wptouch-pro"), __("Settings", "wptouch-pro"), 'manage_options', __FILE__, 'wptouch_admin_panel'); } }
function get_url_for_this_icon($short_icon_name) { if (file_exists(get_wptouch_directory() . '/resources/icons/sets/' . $short_icon_name)) { return get_wptouch_url() . '/resources/icons/sets/' . $short_icon_name; } }