?> array ( array( "name" => "

Options

", "type" => "heading"), ), 'global' => array ( array( "name" => "

Global Options

", "type" => "heading"), array( "name" => "Membership Login?", "desc" => "Check to disable the members login area
NOTE: To make use of the register & login links you must first enable registrations
from your admin general settings page.

", "id" => $shortname."_regs", "std" => "true", "type" => "checkbox"), array( "name" => "Disable Drop-Downs?", "desc" => "Check to disable the drop-down functionality of the main menu

", "id" => $shortname."_showdropdown", "std" => "true", "type" => "checkbox"), array( "name" => "Custom RSS feed", "desc" => "Enter your custom RSS feed URL from services such as Feedburner
(or leave blank to use the standard Wordpress RSS feed)

", "id" => $shortname."_customrss", "std" => "", "type" => "text"), array( "name" => "RSS Link Text", "desc" => "Enter some text to link to your RSS feed
(or leave blank to use the default text)

", "id" => $shortname."_rsstitle", "std" => "", "type" => "text"), array( "name" => "Disable Wordpress Logo?", "desc" => "Check to disable the Wordpress logo in the theme footer

", "id" => $shortname."_lovewp", "std" => "true", "type" => "checkbox"), ), 'frontpage' => array ( array( "name" => "

Frontpage Settings

", "type" => "heading"), array( "name" => "More News", "desc" => "Edit the 'More News' block title here
(or leave blank to use the default text)

", "id" => $shortname."_textmorenews", "std" => "", "type" => "text"), array( "name" => "Google Ads (left)", "desc" => "Edit the 'Ads by Google' block title here (Banner #4)
(or leave blank to use the default text)

", "id" => $shortname."_textbanner4", "std" => "", "type" => "text"), array( "name" => "Latest Headlines", "desc" => "Edit the 'Latest Headlines' block title here
(or leave blank to use the default text)

", "id" => $shortname."_textheadlines", "std" => "", "type" => "text"), array( "name" => "Photo of the Day", "desc" => "Edit the 'Photo of the Day' block title here
(or leave blank to use the default text)

", "id" => $shortname."_textphotoday", "std" => "", "type" => "text"), array( "name" => "Have You Read?", "desc" => "Edit the 'Have You Read?' block title here
(or leave blank to use the default text)

", "id" => $shortname."_texthaveu", "std" => "", "type" => "text"), array( "name" => "Spotlight", "desc" => "Edit the 'Spotlight' block title here
(or leave blank to use the default text)

", "id" => $shortname."_textspotlight", "std" => "", "type" => "text"), array( "name" => "Google Ads (right)", "desc" => "Edit the 'Ads by Google' block title here (Banner #5)
(or leave blank to use the default text)

", "id" => $shortname."_textbanner5", "std" => "", "type" => "text"), ), 'banner' => array ( array( "name" => "

Banner Settings

", "type" => "heading"), array( "name" => "Banner #1", "desc" => "Add your 728*90 banner code here, or leave blank to not show this banner

", "id" => $shortname."_banner1", "std" => "", "type" => "textarea"), array( "name" => "Banner #2", "desc" => "Add your 300*66 banner code here, or leave blank to not show this banner

", "id" => $shortname."_banner2", "std" => "", "type" => "textarea"), array( "name" => "Banner #3", "desc" => "Add your 300*250 banner code here, or leave blank to not show this banner

", "id" => $shortname."_banner3", "std" => "", "type" => "textarea"), array( "name" => "Banner #4", "desc" => "Add your 336*280 banner code here, or leave blank to not show this banner

", "id" => $shortname."_banner4", "std" => "", "type" => "textarea"), array( "name" => "Banner #5", "desc" => "Add your 200*200 banner code here, or leave blank to not show this banner

", "id" => $shortname."_banner5", "std" => "", "type" => "textarea"), array( "name" => "Banner #6", "desc" => "Add your 300*250 banner code here, or leave blank to not show this banner

", "id" => $shortname."_banner6", "std" => "", "type" => "textarea"), ), 'livechat' => array ( array( "name" => "

Livechat Settings

", "type" => "heading"), array( "name" => "Chat Code", "desc" => "Enter your ShoutMix chatcode here as shown in the user guide
(or leave blank to disable all livechat functionality)

NOTE: Activating the live chat feature will invalidate the code.

", "id" => $shortname."_chatcode", "std" => "", "type" => "textarea"), array( "name" => "Chat Link Text", "desc" => "Enter some text to use as the LiveChat toggle text
(or leave blank to use the default text)

", "id" => $shortname."_livechattitle", "std" => "", "type" => "text"), array( "name" => "Members Only?", "desc" => "Check to make the livechat a members-only feature

", "id" => $shortname."_chatregs", "std" => "true", "type" => "checkbox"), ), 'video' => array ( array( "name" => "

Featured Video

", "type" => "heading"), array( "name" => "Video Code", "desc" => "Enter your video embed code here, or leave blank to disable
(Resize videos to 214* 175)

", "id" => $shortname."_videofeat", "std" => "", "type" => "textarea"), array( "name" => "Video Title", "desc" => "Enter the video block title text
(or leave blank to use the default text)

", "id" => $shortname."_videotitle", "std" => "", "type" => "text"), array( "name" => "Members Only?", "desc" => "Check to make the featured video a members-only feature

", "id" => $shortname."_videoregs", "std" => "true", "type" => "checkbox"), ), 'misc' => array ( array( "name" => "

Miscellaneous Settings

", "type" => "heading"), array( "name" => "META Keywords", "desc" => "Add some keywords that are relevant to your website
(seperate with comma's)

", "id" => $shortname."_keywords", "std" => "", "type" => "textarea"), array("name" => "META Description", "desc" => "Enter a description of your site for the search engines

", "id" => $shortname."_description", "std" => "", "type" => "textarea"), array( "name" => "Google Analytics", "desc" => "Add your Google Analytics tracking code here
(or leave blank to not track your stats)

", "id" => $shortname."_analytics", "std" => "", "type" => "textarea"), array( "name" => "Additional Code", "desc" => "Here you can add code that will be positioned directly after your closing body
tag
(HTML allowed)

", "id" => $shortname."_afterbody", "std" => "", "type" => "textarea"), ), 'copyright' => array ( array( "name" => "

Copyright Information

", "type" => "heading"), array( "name" => "Years Protected", "desc" => "Edit the years of copyright
EXAMPLE: 1997 - 2009

", "id" => $shortname."_crightyear", "std" => "", "type" => "text"), array( "name" => "Copyright Holder", "desc" => "Edit the copyright holders name
EXAMPLE: Your Company Name

", "id" => $shortname."_cright", "std" => "", "type" => "text"), array( "name" => "Link Destination", "desc" => "Edit the destination of the copyright holders link
EXAMPLE: http://yourcompany.com

", "id" => $shortname."_crighturl", "std" => "", "type" => "text"), array( "name" => "Your Rights", "desc" => "Edit the rights reserved text
EXAMPLE: All rights reserved.

", "id" => $shortname."_crightsub", "std" => "", "type" => "text"), ), ); function mytheme_add_admin() { global $themename, $shortname,$menu,$agi_options; $arrs =array( 'mt_agi_manage_page', 'mt-agi-global-settings-page', 'mt-agi-frontpage-settings-page', 'mt-agi-banner-settings-page', 'mt-agi-livechat-settings-page', 'mt-agi-video-settings-page', 'mt-agi-misc-settings-page', 'mt-agi-copyright-settings-page', 'mt-agi-page1name-page', 'mt-agi-page2name-page', ); if ( in_array($_REQUEST['page'],$arrs) ) { if ( 'save' == $_REQUEST['action'] ) { foreach ($agi_options[$_REQUEST['agi']] as $value) { if($value['type'] != 'multicheck'){ update_option( $value['id'], $_REQUEST[ $value['id'] ] ); }else{ foreach($value['options'] as $mc_key => $mc_value){ $up_opt = $value['id'].'_'.$mc_key; update_option($up_opt, $_REQUEST[$up_opt] ); } } } foreach ($agi_options as $value) { if($value['type'] != 'multicheck'){ if( isset( $_REQUEST[ $value['id'] ] ) ) { update_option( $value['id'], $_REQUEST[ $value['id'] ] ); } else { delete_option( $value['id'] ); } }else{ foreach($value['options'] as $mc_key => $mc_value){ $up_opt = $value['id'].'_'.$mc_key; if( isset( $_REQUEST[ $up_opt ] ) ) { update_option( $up_opt, $_REQUEST[ $up_opt ] ); } else { delete_option( $up_opt ); } } } } //header("Location: themes.php?page=".$_REQUEST['page']."&saved=true"); // die; } else if( 'reset' == $_REQUEST['action'] ) { foreach ($agi_options as $value) { if($value['type'] != 'multicheck'){ delete_option( $value['id'] ); }else{ foreach($value['options'] as $mc_key => $mc_value){ $del_opt = $value['id'].'_'.$mc_key; delete_option($del_opt); } } } //header("Location: themes.php?page=".$_REQUEST['page']."&reset=true"); //die; } } // Add a new top-level menu (ill-advised): add_menu_page('WPSN', 'WPSN', 10, 'mt-agi-global-settings-page', 'mt_agi_global_settings_page'); unset($menu[90][1]); // Global Settings: add_submenu_page('mt-agi-global-settings-page', 'Global Options', 'Global Options', 8, 'mt-agi-global-settings-page', 'mt_agi_global_settings_page'); // Frontpage Settings: add_submenu_page('mt-agi-global-settings-page', 'Frontpage Settings', 'Frontpage Settings', 8, 'mt-agi-frontpage-settings-page', 'mt_agi_frontpage_settings_page'); // Banner Settings: add_submenu_page('mt-agi-global-settings-page', 'Banner Settings', 'Banner Settings', 8, 'mt-agi-banner-settings-page', 'mt_agi_banner_settings_page'); // Livechat Settings: add_submenu_page('mt-agi-global-settings-page', 'Livechat Settings', 'Livechat Settings', 8, 'mt-agi-livechat-settings-page', 'mt_agi_livechat_settings_page'); // Video Settings: add_submenu_page('mt-agi-global-settings-page', 'Video Settings', 'Video Settings', 8, 'mt-agi-video-settings-page', 'mt_agi_video_settings_page'); // Miscellaneous Settings: add_submenu_page('mt-agi-global-settings-page', 'Miscellaneous', 'Miscellaneous', 8, 'mt-agi-misc-settings-page', 'mt_agi_misc_settings_page'); // Copyright Settings: add_submenu_page('mt-agi-global-settings-page', 'Copyright Info', 'Copyright Info', 8, 'mt-agi-copyright-settings-page', 'mt_agi_copyright_settings_page'); } function mytheme_admin() { global $themename, $shortname, $agi_options; if ( $_REQUEST['saved'] ) echo '

'.$themename.' settings saved.

'; if ( $_REQUEST['reset'] ) echo '

'.$themename.' settings reset.

'; } function mytheme_wp_head() { $stylesheet = get_option('stylewp_alt'); if($stylesheet != ''){?> ', ']]>', $content); $content = strip_tags($content); if (strlen($_GET['p']) > 0) { echo "

"; echo $content; echo " "."Read More →"; echo "

"; } else if ((strlen($content)>$max_char) && ($espacio = strpos($content, " ", $max_char ))) { $content = substr($content, 0, $espacio); $content = $content; echo "

"; echo $content; echo "..."; echo " ".$more_link_text.""; echo "

"; } else { echo "

"; echo $content; echo " "."Read More →"; echo "

"; } } /* function mt_agi_page1_function_callback(){ global $shortname; echo ""; $agi_options = array ( array( "name" => "

Option page 1

", "type" => "heading"), array( "name" => "screenshot", "id" => "screenshot", 'url'=>get_template_directory_uri()."/screenshot.png", "type" => "screenshot"), ); agi_template($agi_options,'welcome'); } function mt_agi_page2_function_callback(){ $agi_options = array ( array( "name" => "

Option page 2

", "type" => "heading") ); agi_template($agi_options,'welcome'); } */ function mt_agi_manage_page(){ global $agi_options; agi_template($agi_options['welcome'],'welcome'); } function mt_agi_global_settings_page(){ global $agi_options; agi_template($agi_options['global'],'global'); } function mt_agi_frontpage_settings_page(){ global $agi_options; agi_template($agi_options['frontpage'],'frontpage'); } function mt_agi_banner_settings_page(){ global $agi_options; agi_template($agi_options['banner'],'banner'); } function mt_agi_livechat_settings_page(){ global $agi_options; agi_template($agi_options['livechat'],'livechat'); } function mt_agi_video_settings_page(){ global $agi_options; agi_template($agi_options['video'],'video'); } function mt_agi_misc_settings_page(){ global $agi_options; agi_template($agi_options['misc'],'misc'); } function mt_agi_copyright_settings_page(){ global $agi_options; agi_template($agi_options['copyright'],'copyright'); } function agi_template($options=array(),$agi=''){ if(count($options)!=1){ ?>
" />

In order to test screenshot preview roll over the Css Globe link.