{ $categories = get_categories('hide_empty=0'); $categories_array[] = array('value' => '0', 'title' => 'Select'); foreach ($categories as $cat) { if ($cat->category_count == '0') { $posts_title = 'No posts!'; } elseif ($cat->category_count == '1') { $posts_title = '1 post'; } else { $posts_title = $cat->category_count . ' posts'; } $categories_array[] = array('value' => $cat->cat_ID, 'title' => $cat->cat_name . ' ( ' . $posts_title . ' )'); } return $categories_array; } $options = array(array("type" => "open"), array("name" => "Logo Image", "desc" => "Enter the logo image full path. Leave it blank if you don't want to use logo image.", "id" => $shortname . "_logo", "std" => get_bloginfo('template_url') . "/images/logo.png", "type" => "text"), array("name" => "Featured Posts Enabled?", "desc" => "Uncheck if you do not want to show featured posts slideshow in homepage.", "id" => $shortname . "_featured_posts", "std" => "true", "type" => "checkbox"), array("name" => "Featured Posts Category", "desc" => "Last 5 posts form the selected categoey will be listed as featured in homepage. <br />The selected category should contain at last 2 posts with images. <br /> <br /> <b>How to add images to your featured posts slideshow?</b> <br />\n <b>»</b> If you are using WordPress version 2.9 and above: Just set \"Post Thumbnail\" when adding new post for the posts in selected category above. <br /> \n <b>»</b> If you are using WordPress version under 2.9 you have to add custom fields in each post on the category you set as featured category. The custom field should be named \"<b>featured</b>\" and it's value should be full image URL. <a href=\"http://newwpthemes.com/public/featured_custom_field.jpg\" target=\"_blank\">Click here</a> for a screenshot. <br /> <br />\n In both situation, the image sizes should be: Width: <b>480 px</b>. Height: <b>280 px.</b>", "id" => $shortname . "_featured_posts_category", "options" => cats_to_select(), "std" => "0", "type" => "select"), array("name" => "Header Banner (468x60 px)", "desc" => "Header banner code. You may use any html code here, including your 468x60 px Adsense code.", "id" => $shortname . "_ad_header", "type" => "textarea", "std" => '<a href="http://flexithemes.com/?partner=19"><img src="http://flexithemes.com/wp-content/partners/ftb.gif" style="border: 0;" alt="Premium WordPress Themes" /></a>'), array("name" => "Sidebar 125x125 px Ads", "desc" => "Add your 125x125 px ads here. You can add unlimited ads. Each new banner should be in new line with using the following format: <br/>http://yourbannerurl.com/banner.gif, http://theurl.com/to_link.html", "id" => $shortname . "_ads_125", "type" => "textarea", "std" => 'http://newwpthemes.com/uploads/newwp/newwp12.png,http://newwpthemes.com/ http://flexithemes.com/wp-content/partners/fta.gif, http://flexithemes.com/?partner=19 http://newwpthemes.com/hosting/wpwh12.gif, http://newwpthemes.com/hosting/wpwebhost.php'), array("name" => "Twitter", "desc" => "Enter your twitter account url here.", "id" => $shortname . "_twitter", "std" => "http://twitter.com/WPTwits", "type" => "text"), array("name" => "Twitter Text", "desc" => "", "id" => $shortname . "_twittertext", "std" => "Follow Us", "type" => "text"), array("name" => "Rss Box", "desc" => "Show RSS subscription box above sidebar(s)?", "id" => $shortname . "_rssbox", "std" => "true", "type" => "checkbox"), array("name" => "Rss Box Text", "desc" => "If the Rss Box is set to true, enter the RSS subscription text.", "id" => $shortname . "_rssboxtext", "std" => "Subscribe", "type" => "text"), array("name" => "Social Network Icons", "desc" => "Show the social network share icons above sidebar(s)?", "id" => $shortname . "_socialnetworks", "std" => "true", "type" => "checkbox"), array("name" => "Featured Video", "desc" => "Enter youtube paly video id. Example: http://www.youtube.com/watch?v=<b>SxNJTWZVOQk</b>.", "id" => $shortname . "_video", "std" => 'SxNJTWZVOQk', "type" => "text"), array("name" => "Sidebar 1 Bottom Banner. Max width 125 px. Recommended 120x600 px banner", "desc" => "Sidebar 1 Bottom Banner code.", "id" => $shortname . "_ad_sidebar1_bottom", "type" => "textarea", "std" => '<a href="http://flexithemes.com/?partner=19"><img src="http://flexithemes.com/wp-content/partners/ftf.gif" style="border: 0;" alt="Premium WordPress Themes" /></a>'), array("name" => "Sidebar 2 Bottom Banner. Max width 260 px. Recommended 250x250 px banner", "desc" => "Sidebar 2 Bottom Banner code.", "id" => $shortname . "_ad_sidebar2_bottom", "type" => "textarea", "std" => '<a href="http://graphicriver.net?ref=pluswebdev"><img src="http://themeforest.net/new/images/ms_referral_banners/GR_120x600.jpg" /></a>'), array("name" => "Head Scrip(s)", "desc" => "The content of this box will be added immediately before </head> tag. Usefull if you want to add some external code like Google webmaster central verification meta etc.", "id" => $shortname . "_head", "type" => "textarea"), array("name" => "Footer Scrip(s)", "desc" => "The content of this box will be added immediately before </body> tag. Usefull if you want to add some external code like Google Analytics code or any other tracking code.", "id" => $shortname . "_footer", "type" => "textarea"), array("type" => "close")); function mytheme_add_admin() { global $themename, $shortname, $options; if ($_GET['page'] == basename(__FILE__)) { if ('save' == $_REQUEST['action']) { foreach ($options as $value) { update_option($value['id'], $_REQUEST[$value['id']]); } foreach ($options as $value) { if (isset($_REQUEST[$value['id']])) { update_option($value['id'], $_REQUEST[$value['id']]); } else { delete_option($value['id']);
$categories = get_categories('hide_empty=0'); $categories_array[] = array('value' => '0', 'title' => 'Select'); foreach ($categories as $cat) { if ($cat->category_count == '0') { $posts_title = 'No posts!'; } elseif ($cat->category_count == '1') { $posts_title = '1 post'; } else { $posts_title = $cat->category_count . ' posts'; } $categories_array[] = array('value' => $cat->cat_ID, 'title' => $cat->cat_name . ' ( ' . $posts_title . ' )'); } return $categories_array; } $options = array(array("type" => "open"), array("name" => "Logo Image", "desc" => "Enter the logo image full path or Upload your Logo. Leave it blank if you don't want to use logo image. You can edit LOGO.psd, which is theme folder. <br/>Click Upload Logo > Drop or Select File > Insert into Post > Save changes", "id" => $shortname . "_logo", "std" => get_bloginfo('template_url') . "/images/logo.png", "type" => "image_upload"), array("name" => "Footer Logo Image", "desc" => "Enter the logo image full path or Upload your Logo. Leave it blank if you don't want to use logo image. You can edit LOGO.psd, which is theme folder. <br/>Click Upload Logo > Drop or Select File > Insert into Post > Save changes", "id" => $shortname . "_logofooter", "std" => get_bloginfo('template_url') . "/images/footer_logo.gif", "type" => "footer_upload"), array("name" => "Top Banner", "desc" => "Enter the banner image full path or Upload your Banner. Leave it blank if you don't want to use a banner image. <br/>Click Upload Banner > Drop or Select File > Insert into Post > Save changes", "id" => $shortname . "_topbanner", "std" => get_bloginfo('template_url') . "/images/top-banner/STC.png", "type" => "banner_upload"), array("name" => "Top Banner URL", "desc" => "Enter a URL link for this banner. Example: http://www.mcauniversal.com.ph/</b>.", "id" => $shortname . "_topbanner-url", "std" => '/beta', "type" => "text"), array("name" => "Opm Banner", "desc" => "Enter the banner image full path or Upload your Banner for OPM Page. Leave it blank if you don't want to use a banner image. <br/>Click Upload OPM Banner > Drop or Select File > Insert into Post > Save changes", "id" => $shortname . "_opmbanner", "std" => get_bloginfo('template_url') . "/images/top-banner/STC.png", "type" => "opm_upload"), array("name" => "Menu Options", "desc" => "Please, use the <a href=\"nav-menus.php\">menus panel</a> to manage and organize menu items for the primary and secondary menu.The primary menu will display the pages list if no menu is selected from the menus panel. The Secondary menu will display categories if no menu selected in menu panel..", "type" => "none"), array("name" => "Read More Link", "desc" => "If you prefer to show Read more link on homepage, than when you write new posts make sure you click Insert More Tag, check <a href=\"http://themepix.com/pix/img/insert-more-tag.jpg\" target=\"_blank\">check this image</a>.", "type" => "none"), array("name" => "Popular Posts Enabled?", "desc" => "Uncheck if you do not want to show Popular Posts with Thumbnail in Sidebar.", "id" => $shortname . "_popular_posts", "std" => "true", "type" => "checkbox"), array("name" => "Featured Video (Home)", "desc" => "Enter youtube video id. Example: http://www.youtube.com/watch?v=<b>V7P6E69aihY</b>. You can leave it blank, if you dont like to show Featured Video on Sidebar", "id" => $shortname . "_video", "std" => 'V7P6E69aihY', "type" => "text"), array("name" => "Featured Video (Artist)", "desc" => "Enter youtube video id. Example: http://www.youtube.com/watch?v=<b>V7P6E69aihY</b>. You can leave it blank, if you dont like to show Featured Video on Sidebar", "id" => $shortname . "_video-artist", "std" => 'V7P6E69aihY', "type" => "text"), array("name" => "Head Script(s)", "desc" => "The content of this box will be added immediately before </head> tag. Useful if you want to add some external code like Google webmaster central verification meta etc.", "id" => $shortname . "_head", "type" => "textarea"), array("name" => "Footer Script(s)", "desc" => "The content of this box will be added immediately before </body> tag. Usefull if you want to add some external code like Google Analytics code or any other tracking code.", "id" => $shortname . "_footer", "type" => "textarea"), array("type" => "close")); $options2 = array(array("type" => "open"), array("name" => "How to Setup the Slidershow?", "desc" => "Its really simple, no need to do any image replace, this works automatically, just follow those steps: <br/>Create a New post > <a href=\"http://themepix.com/pix/img/set-feature-image.jpg\" target=\"_blank\">Set feauture image</a> > Select (or add new) category > Publish > Came again here (theme option) > Select slideshow category below.", "type" => "none"), array("name" => "Slidershow Enabled?", "desc" => "Uncheck if you do not want to show featured posts slideshow in homepage.", "id" => $shortname . "_featured_posts", "std" => "true", "type" => "checkbox"), array("name" => "Slidershow Category", "desc" => "Last posts form the selected category will be listed as featured at homepage. <br />The selected category should contain feature images, so when you create new posts you should <b>set feature image</b>.", "id" => $shortname . "_featured_posts_category", "options" => cats_to_select(), "std" => "0", "type" => "select"), array("type" => "close")); $options3 = array(array("type" => "open"), array("name" => "Twitter Widget Enabled?", "desc" => "Check it, to show Twitter widget on your sidebar. To customize it, go to Widget and enter your profile url. Uncheck if you do not want to show Twitter Widget in sidebar.", "id" => $shortname . "_twitter_widget", "std" => "true", "type" => "checkbox"), array("name" => "Facebook Widget Enabled?", "desc" => "Check it, to show Facebook widget on your sidebar. To customize it, go to Widgets and enter your profile url. Uncheck if you do not want to show Facebook Widget in sidebar.", "id" => $shortname . "_facebook_widget", "std" => "true", "type" => "checkbox"), array("name" => "Social Network Icons", "desc" => "Show the social icons above sidebar? Uncheck it, if you dont want to be displayed. Also, below you can enter your social url profiles.", "id" => $shortname . "_socialnetworks", "std" => "true", "type" => "checkbox"), array("name" => "RSS", "desc" => "Add your Feedburner URL, or any other RSS link. Leave it blank if you dont like the RSS icon to be displayed.", "id" => $shortname . "_rss", "std" => "http://feeds.feedburner.com/themepixcom", "type" => "text"), array("name" => "Facebook", "desc" => "Add your Facebook URL profile, to link the facebook icon to your profile. Leave it blank if you dont like the Facebook icon to be displayed.", "id" => $shortname . "_facebook", "std" => "http://facebook.com/ThemePix", "type" => "text"), array("name" => "Twitter", "desc" => "Add your Twitter URL profile, to link the Twitter icon to your profile. Leave it blank if you dont like the Twitter icon to be displayed.", "id" => $shortname . "_twitter", "std" => "http://twitter.com/ThemePix", "type" => "text"), array("name" => "GooglePlus", "desc" => "Add your Google Plus URL profile, to link the Google Plus icon to your profile. Leave it blank if you dont like the Google Plus icon to be displayed.", "id" => $shortname . "_googleplus", "std" => "https://plus.google.com/105902409914354750342/", "type" => "text"), array("name" => "LinkedIn", "desc" => "Add your LinkedIn URL profile, to link the LinkedIn icon to your profile. Leave it blank if you dont like the LinkedIn icon to be displayed.", "id" => $shortname . "_linkedin", "std" => "http://linkedin.com/yourprofile", "type" => "text"), array("name" => "YouTube", "desc" => "Add your YouTube URL profile, to link the YouTube icon to your profile. Leave it blank if you dont like the YouTube icon to be displayed.", "id" => $shortname . "_youtube", "std" => "http://youtube.com/yourprofile", "type" => "text"), array("name" => "eMail", "desc" => "Add your eMail here, to link the eMail icon to your address. Leave it blank if you dont like the eMail icon to be displayed.", "id" => $shortname . "_email", "std" => "mailto:contact@themepix.com", "type" => "text"), array("name" => "Other Social Icons?", "desc" => "You can replace the actual social icons with new ones. For example, if you dont have a YouTube channel, and you dont need it, but you want to replace with other social icon, like Pinterest. OK now paste your Pinterest profile URL at YouTube box, and after go to theme folder and open images/social-icons/ and replace YouTube icon with Pinterest icon, make sure than Pinterest icon has name youtube.png", "type" => "none"), array("type" => "close")); $options4 = array(array("type" => "open"), array("name" => "Sidebar Top Ad Zone (125x125 px)", "desc" => "Top Sidebar Banner code. You may use any html code here, including your 250x250 px Adsense code. Also, you can edit the links and image url from code above, if you prefer to show 125x125 px ads. Leave it blank if you dont want to display ads.", "id" => $shortname . "_ad_sidebar_top", "type" => "textarea", "std" => '<a href="http://themepix.com"><img class="sidebaradbox" src="http://themepix.com/pix/uploads/ad-125.png" style="border: 0;" alt="Advertise Here" /></a> <a href="http://themepix.com"><img class="sidebaradbox" src="http://themepix.com/pix/uploads/ad2-125.png" style="border: 0;" alt="Advertise Here" /></a>'), array("name" => "Sidebar Bottom Banner", "desc" => "You may use any html code here, including your 250x250 px Adsense code. Leave it blank if you dont want to display ads.", "id" => $shortname . "_ad_sidebar1_bottom", "type" => "textarea", "std" => '<a href="http://themepix.com"><img src="http://themepix.com/pix/uploads/ad-250.png" style="border: 0;" alt="Advertise Here" /></a>'), array("name" => "More Ads Placement", "desc" => "Yes, you can place more ads on sidebar. Please, use the <a href=\"widgets.php\">widgets</a> and drag and drop Text Widget to paste your ad script or Google adsense code.", "type" => "none"), array("type" => "close")); function mytheme_add_admin() { global $themename, $shortname, $options, $options2, $options3, $options4; if ($_GET['page'] == basename(__FILE__)) { if ('save' == $_REQUEST['action']) { foreach ($options as $value) { update_option($value['id'], $_REQUEST[$value['id']]); } foreach ($options as $value) { if (isset($_REQUEST[$value['id']])) { update_option($value['id'], $_REQUEST[$value['id']]); } else {
{ $categories = get_categories('hide_empty=0'); $categories_array[] = array('value' => '0', 'title' => 'Select'); foreach ($categories as $cat) { if ($cat->category_count == '0') { $posts_title = 'No posts!'; } elseif ($cat->category_count == '1') { $posts_title = '1 post'; } else { $posts_title = $cat->category_count . ' posts'; } $categories_array[] = array('value' => $cat->cat_ID, 'title' => $cat->cat_name . ' ( ' . $posts_title . ' )'); } return $categories_array; } $options = array(array("type" => "open"), array("name" => "Logo Image", "desc" => "Enter the logo image full path or Upload your Logo. Leave it blank if you don't want to use logo image. You can edit LOGO.psd, which is theme folder. <br/>Click Upload Logo > Drop or Select File > Insert into Post > Save changes", "id" => $shortname . "_logo", "std" => get_bloginfo('template_url') . "/images/logo.png", "type" => "image_upload"), array("name" => "Slidershow Enabled?", "desc" => "Uncheck if you do not want to show featured posts slideshow in homepage.", "id" => $shortname . "_featured_posts", "std" => "true", "type" => "checkbox"), array("name" => "Slidershow Category", "desc" => "Last posts form the selected category will be listed as featured at homepage. <br />The selected category should contain feature images, so when you create new posts you should <b>set feature image</b>.", "id" => $shortname . "_featured_posts_category", "options" => cats_to_select(), "std" => "0", "type" => "select"), array("name" => "Menu Options", "desc" => "Please, use the <a href=\"nav-menus.php\">menus panel</a> to manage and organize menu items for the primary and secondary menu.The primary menu will display the pages list if no menu is selected from the menus panel. The Secondary menu will display categories if no menu selected in menu panel..", "type" => "none"), array("name" => "Populer Posts Enabled?", "desc" => "Uncheck if you do not want to show Populer Posts with Thumbnail in Sidebar.", "id" => $shortname . "_populer_posts", "std" => "true", "type" => "checkbox"), array("name" => "Featured Video", "desc" => "Enter youtube play video id. Example: http://www.youtube.com/watch?v=<b>V7P6E69aihY</b>. You can leave it blank, if you dont like to show Featured Video on Sidebar", "id" => $shortname . "_video", "std" => 'V7P6E69aihY', "type" => "text"), array("name" => "Head Scrip(s)", "desc" => "The content of this box will be added immediately before </head> tag. Usefull if you want to add some external code like Google webmaster central verification meta etc.", "id" => $shortname . "_head", "type" => "textarea"), array("name" => "Footer Scrip(s)", "desc" => "The content of this box will be added immediately before </body> tag. Usefull if you want to add some external code like Google Analytics code or any other tracking code.", "id" => $shortname . "_footer", "type" => "textarea")); $options2 = array(array("type" => "open"), array("name" => "Twitter Widget Enabled?", "desc" => "Check it, to show Twitter widget on your sidebar. To customize it, go to Widget and enter your profile url. Uncheck if you do not want to show Twitter Widget in sidebar.", "id" => $shortname . "_twitter_widget", "std" => "true", "type" => "checkbox"), array("name" => "Facebook Widget Enabled?", "desc" => "Check it, to show Facebook widget on your sidebar. To customize it, go to Widgets and enter your profile url. Uncheck if you do not want to show Facebook Widget in sidebar.", "id" => $shortname . "_facebook_widget", "std" => "true", "type" => "checkbox"), array("name" => "Social Network Icons", "desc" => "Show the social icons above sidebar? Uncheck it, if you dont want to be displayed. Also, below you can enter your social url profiles.", "id" => $shortname . "_socialnetworks", "std" => "true", "type" => "checkbox"), array("name" => "RSS", "desc" => "Add your Feedburner URL, or any other RSS link. Leave it blank if you dont like the RSS icon to be displayed.", "id" => $shortname . "_rss", "std" => "http://feeds.feedburner.com/themepixcom", "type" => "text"), array("name" => "Facebook", "desc" => "Add your Facebook URL profile, to link the facebook icon to your profile. Leave it blank if you dont like the Facebook icon to be displayed.", "id" => $shortname . "_facebook", "std" => "http://facebook.com/ThemePix", "type" => "text"), array("name" => "Twitter", "desc" => "Add your Twitter URL profile, to link the Twitter icon to your profile. Leave it blank if you dont like the Twitter icon to be displayed.", "id" => $shortname . "_twitter", "std" => "http://twitter.com/ThemePix", "type" => "text"), array("name" => "GooglePlus", "desc" => "Add your Google Plus URL profile, to link the Google Plus icon to your profile. Leave it blank if you dont like the Google Plus icon to be displayed.", "id" => $shortname . "_googleplus", "std" => "https://plus.google.com/105902409914354750342/", "type" => "text"), array("name" => "LinkedIn", "desc" => "Add your LinkedIn URL profile, to link the LinkedIn icon to your profile. Leave it blank if you dont like the LinkedIn icon to be displayed.", "id" => $shortname . "_linkedin", "std" => "http://linkedin.com/yourprofile", "type" => "text"), array("name" => "YouTube", "desc" => "Add your YouTube URL profile, to link the YouTube icon to your profile. Leave it blank if you dont like the YouTube icon to be displayed.", "id" => $shortname . "_youtube", "std" => "http://youtube.com/yourprofile", "type" => "text"), array("name" => "eMail", "desc" => "Add your eMail here, to link the eMail icon to your address. Leave it blank if you dont like the eMail icon to be displayed.", "id" => $shortname . "_email", "std" => "mailto:contact@themepix.com", "type" => "text"), array("name" => "Other Social Icons?", "desc" => "You can replace the actual social icons with new ones. For example, if you dont have a YouTube channel, and you dont need it, but you want to replace with other social icon, like Pinterest. OK now paste your Pinterest profile URL at YouTube box, and after go to theme folder and open images/social-icons/ and replace YouTube icon with Pinterest icon, make sure than Pinterest icon has name youtube.png", "type" => "none"), array("type" => "close")); $options3 = array(array("type" => "open"), array("name" => "Sidebar Top Ad Zone (125x125 px)", "desc" => "Top Sidebar Banner code. You may use any html code here, including your 250x250 px Adsense code. Also, you can edit the links and image url from code above, if you prefer to show 125x125 px ads.", "id" => $shortname . "_ad_sidebar_top", "type" => "textarea", "std" => '<a href="http://themepix.com"><img class="sidebaradbox" src="http://themepix.com/pix/uploads/ad-125.png" style="border: 0;" alt="Advertise Here" /></a> <a href="http://themepix.com"><img class="sidebaradbox" src="http://themepix.com/pix/uploads/ad2-125.png" style="border: 0;" alt="Advertise Here" /></a>'), array("name" => "Sidebar Bottom Banner", "desc" => "You may use any html code here, including your 250x250 px Adsense code.", "id" => $shortname . "_ad_sidebar1_bottom", "type" => "textarea", "std" => '<a href="http://themepix.com"><img src="http://themepix.com/pix/uploads/ad-250.png" style="border: 0;" alt="Advertise Here" /></a>'), array("name" => "More Ads Placement", "desc" => "Yes, you can place more ads on sidebar. Please, use the <a href=\"widgets.php\">widgets</a> and drag and drop Text Widget to paste your ad script or Google adsense code.", "type" => "none"), array("type" => "close")); function mytheme_add_admin() { global $themename, $shortname, $options, $options2, $options3; if ($_GET['page'] == basename(__FILE__)) { if ('save' == $_REQUEST['action']) { foreach ($options as $value) { update_option($value['id'], $_REQUEST[$value['id']]); } foreach ($options as $value) { if (isset($_REQUEST[$value['id']])) { update_option($value['id'], $_REQUEST[$value['id']]); } else {
{ $categories = get_categories('hide_empty=0'); $categories_array[] = array('value' => '0', 'title' => 'Select'); foreach ($categories as $cat) { if ($cat->category_count == '0') { $posts_title = 'No posts!'; } elseif ($cat->category_count == '1') { $posts_title = '1 post'; } else { $posts_title = $cat->category_count . ' posts'; } $categories_array[] = array('value' => $cat->cat_ID, 'title' => $cat->cat_name . ' ( ' . $posts_title . ' )'); } return $categories_array; } $options = array(array("type" => "open"), array("name" => "Logo Image", "desc" => "Enter the logo image full path. Leave it blank if you don't want to use logo image.", "id" => $shortname . "_logo", "std" => get_bloginfo('template_url') . "/images/logo.png", "type" => "text"), array("name" => "Header Background", "desc" => "Enter the header background image full path. The image will alligned to right. Recommended image height: 150px. Leave it blank if you don't want to use display a header image.", "id" => $shortname . "_header_background", "std" => get_bloginfo('template_url') . "/images/header_background.jpg", "type" => "text"), array("name" => "Featured Posts Enabled?", "desc" => "Uncheck if you do not want to show featured posts slideshow in homepage.", "id" => $shortname . "_featured_posts", "std" => "true", "type" => "checkbox"), array("name" => "Featured Posts Category", "desc" => "Last 5 posts form the selected categoey will be listed as featured at homepage. <br />The selected category should contain at last 2 posts with images. <br /> <br /> <b>How to add images to your featured posts slideshow?</b> <br />\n <b>»</b> If you are using WordPress version 2.9 and above: Just set \"Post Thumbnail\" when adding new post for the posts in selected category above. <br /> \n <b>»</b> If you are using WordPress version under 2.9 you have to add custom fields in each post on the category you set as featured category. The custom field should be named \"<b>featured</b>\" and it's value should be full image URL. <a href=\"http://newwpthemes.com/public/featured_custom_field.jpg\" target=\"_blank\">Click here</a> for a screenshot. <br /> <br />\n In both situation, the image sizes should be: Width: <b>520 px</b>. Height: <b>300 px.</b>", "id" => $shortname . "_featured_posts_category", "options" => cats_to_select(), "std" => "0", "type" => "select"), array("name" => "Sidebar 125x125 px Ads", "desc" => "Add your 125x125 px ads here. You can add unlimited ads. Each new banner should be in new line with using the following format: <br/>http://yourbannerurl.com/banner.gif, http://theurl.com/to_link.html", "id" => $shortname . "_ads_125", "type" => "textarea", "std" => 'http://img861.imageshack.us/img861/4324/adsquarebutton125x125.gif,http://bit.ly/Zx0QIpzl1?/ http://img861.imageshack.us/img861/4324/adsquarebutton125x125.gif, http://bit.ly/Zx0QIpzl1'), array("name" => "Twitter", "desc" => "Enter your twitter account url here.", "id" => $shortname . "_twitter", "std" => "http://twitter.com/Wordpress", "type" => "text"), array("name" => "Twitter Text", "desc" => "", "id" => $shortname . "_twittertext", "std" => "Follow me!", "type" => "text"), array("name" => "Rss Box", "desc" => "Show RSS subscription box above sidebar(s)?", "id" => $shortname . "_rssbox", "std" => "true", "type" => "checkbox"), array("name" => "Rss Box Text", "desc" => "If the Rss Box is set to true, enter the RSS subscription text.", "id" => $shortname . "_rssboxtext", "std" => "RSS Subscription!", "type" => "text"), array("name" => "Sidebar 1 Bottom Banner", "desc" => "Sidebar 1 Bottom Banner code.", "id" => $shortname . "_ad_sidebar1_bottom", "type" => "textarea", "std" => '<a href="http://bit.ly/Zx0QIpzl1"><img src="http://img718.imageshack.us/img718/1151/adskyscraper120x600.gif" style="border: 0;" alt="Premium WordPress Themes" /></a>'), array("name" => "Sidebar 2 Bottom Banner", "desc" => "Sidebar 2 Bottom Banner code.", "id" => $shortname . "_ad_sidebar2_bottom", "type" => "textarea", "std" => '<a href="http://newwpthemes.com"><img src="http://img861.imageshack.us/img861/4324/adsquarebutton125x125.gif" /></a>'), array("name" => "Head Scrip(s)", "desc" => "The content of this box will be added immediately before </head> tag. Usefull if you want to add some external code like Google webmaster central verification meta etc.", "id" => $shortname . "_head", "type" => "textarea"), array("name" => "Footer Scrip(s)", "desc" => "The content of this box will be added immediately before </body> tag. Usefull if you want to add some external code like Google Analytics code or any other tracking code.", "id" => $shortname . "_footer", "type" => "textarea"), array("type" => "close")); function mytheme_add_admin() { global $themename, $shortname, $options; if ($_GET['page'] == basename(__FILE__)) { if ('save' == $_REQUEST['action']) { foreach ($options as $value) { update_option($value['id'], $_REQUEST[$value['id']]); } foreach ($options as $value) { if (isset($_REQUEST[$value['id']])) { update_option($value['id'], $_REQUEST[$value['id']]); } else { delete_option($value['id']); }