Created
August 27, 2010 20:43
-
-
Save jacobfogg/554166 to your computer and use it in GitHub Desktop.
Revisions
-
jacobfogg revised this gist
Aug 27, 2010 . 1 changed file with 15 additions and 3 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -15,8 +15,8 @@ function DJ_HBG_plugin_menu() { add_submenu_page( 'DJ_Main_Menu', 'Hawaii Buyers Guide Settings', 'Hawaii Buyers Guide', 'manage_options', __FILE__, @@ -39,4 +39,16 @@ function DJ_HBG_plugin_options() { ?> //***************** //DataJoe_Main.php: function DJ_menu_setup(){ add_menu_page(__('DataJoe','djo'), __('DataJoe','djo'), 'manage_options', 'DJ_Main_Menu', 'DJ_settings_menu',DJ_main_plugin_url.'/logo_sm.png'); add_submenu_page('DJ_Main_Menu', __('DataJoe - Global Settings','djo'), __('Global Settings','djo'), 'manage_options', 'DJ_Main_Menu', 'DJ_settings_menu'); } add_action('admin_menu', 'DJ_menu_setup'); -
jacobfogg renamed this gist
Aug 27, 2010 . 1 changed file with 0 additions and 0 deletions.There are no files selected for viewing
File renamed without changes. -
jacobfogg created this gist
Aug 27, 2010 .There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,42 @@ <?php /* Plugin Name: DataJoe Hawaii Buyer's Guide Plugin Plugin URI: http://joe4-jacob.datajoe.com/wp Description: Custom plugin built for Hawaii Buyer's Guide to embed a custom interface for their directory on their site. To add the directory to your site, simply include "%%DJ_HBG_page%%" on any page. Version: 0.03 Author: Jacob Fogg Author URI: http://jacobfogg.blogspot.com */ require_once(dirname(dirname(__FILE__)).'/DataJoe_Main/DataJoe_helper.inc'); define('DJ_main_plugin_url', WP_PLUGIN_URL.'/'.dirname(plugin_basename(__FILE__))); add_action('admin_menu', 'DJ_HBG_plugin_menu'); function DJ_HBG_plugin_menu() { add_submenu_page( DJ_MAIN_PLUGIN_DIR, 'Hawaii Buyers Guide', 'Hawaii Buyers Guide', 'manage_options', __FILE__, 'DJ_HBG_plugin_options' ); } function DJ_HBG_plugin_options() { echo "test"; if (!current_user_can('manage_options')) { wp_die( __('You do not have sufficient permissions to access this page888.') ); } echo '<div class="wrap">'; echo '<p>Here is where the form would go if I actually had options.</p>'; echo '</div>'; } ?>