Exemple #1
0
 function woo_options()
 {
     // VARIABLES
     $themename = "Inspire";
     $manualurl = 'http://www.woothemes.com/support/theme-documentation/inspire/';
     $shortname = "woo";
     $GLOBALS['template_path'] = get_bloginfo('template_directory');
     //Access the WordPress Categories via an Array
     $woo_categories = array();
     $woo_categories_obj = get_categories('hide_empty=0');
     foreach ($woo_categories_obj as $woo_cat) {
         $woo_categories[$woo_cat->cat_ID] = $woo_cat->cat_name;
     }
     $categories_tmp = array_unshift($woo_categories, "Select a category:");
     //Access the WordPress Pages via an Array
     $woo_pages = array();
     $woo_pages_obj = get_pages('sort_column=post_parent,menu_order');
     foreach ($woo_pages_obj as $woo_page) {
         $woo_pages[$woo_page->ID] = $woo_page->post_name;
     }
     $woo_pages_tmp = array_unshift($woo_pages, "Select a page:");
     // Image Alignment radio box
     $options_thumb_align = array("alignleft" => "Left", "alignright" => "Right", "aligncenter" => "Center");
     // Image Links to Options
     $options_image_link_to = array("image" => "The Image", "post" => "The Post");
     //Testing
     $options_select = array("one", "two", "three", "four", "five");
     $options_radio = array("one" => "One", "two" => "Two", "three" => "Three", "four" => "Four", "five" => "Five");
     //URL Shorteners
     if (_iscurlinstalled()) {
         $options_select = array("Off", "TinyURL", "Bit.ly");
         $short_url_msg = 'Select the URL shortening service you would like to use.';
     } else {
         $options_select = array("Off");
         $short_url_msg = '<strong>cURL was not detected on your server, and is required in order to use the URL shortening services.</strong>';
     }
     //Stylesheets Reader
     $alt_stylesheet_path = TEMPLATEPATH . '/styles/';
     $alt_stylesheets = array();
     if (is_dir($alt_stylesheet_path)) {
         if ($alt_stylesheet_dir = opendir($alt_stylesheet_path)) {
             while (($alt_stylesheet_file = readdir($alt_stylesheet_dir)) !== false) {
                 if (stristr($alt_stylesheet_file, ".css") !== false) {
                     $alt_stylesheets[] = $alt_stylesheet_file;
                 }
             }
         }
     }
     //More Options
     $other_entries = array("Select a number:", "1", "2", "3", "4", "5", "6", "7", "8", "9", "10", "11", "12", "13", "14", "15", "16", "17", "18", "19");
     $body_repeat = array("no-repeat", "repeat-x", "repeat-y", "repeat");
     $body_pos = array("top left", "top center", "top right", "center left", "center center", "center right", "bottom left", "bottom center", "bottom right");
     // THIS IS THE DIFFERENT FIELDS
     $options = array();
     $options[] = array("name" => "General Settings", "icon" => "general", "type" => "heading");
     $options[] = array("name" => "Theme Stylesheet", "desc" => "Select your theme's alternative color scheme.", "id" => $shortname . "_alt_stylesheet", "std" => "default.css", "type" => "select", "options" => $alt_stylesheets);
     $options[] = array("name" => "Custom Logo", "desc" => "Upload a logo for your theme, or specify an image URL directly.", "id" => $shortname . "_logo", "std" => "", "type" => "upload");
     $options[] = array("name" => "Text Title", "desc" => "Enable if you want Blog Title and Tagline to be text-based. Setup title/tagline in WP -> Settings -> General.", "id" => $shortname . "_texttitle", "std" => "false", "type" => "checkbox");
     $options[] = array("name" => "Custom Favicon", "desc" => "Upload a 16px x 16px <a href='http://www.faviconr.com/'>ico image</a> that will represent your website's favicon.", "id" => $shortname . "_custom_favicon", "std" => "", "type" => "upload");
     $options[] = array("name" => "Tracking Code", "desc" => "Paste your Google Analytics (or other) tracking code here. This will be added into the footer template of your theme.", "id" => $shortname . "_google_analytics", "std" => "", "type" => "textarea");
     $options[] = array("name" => "RSS URL", "desc" => "Enter your preferred RSS URL. (Feedburner or other)", "id" => $shortname . "_feed_url", "std" => "", "type" => "text");
     $options[] = array("name" => "E-Mail URL", "desc" => "Enter your preferred E-mail subscription URL. (Feedburner or other)", "id" => $shortname . "_subscribe_email", "std" => "", "type" => "text");
     $options[] = array("name" => "Contact Form E-Mail", "desc" => "Enter your E-mail address to use on the Contact Form Page Template. Add the contact form by adding a new page and selecting 'Contact Form' as page template.", "id" => $shortname . "_contactform_email", "std" => "", "type" => "text");
     $options[] = array("name" => "Custom CSS", "desc" => "Quickly add some CSS to your theme by adding it to this block.", "id" => $shortname . "_custom_css", "std" => "", "type" => "textarea");
     $options[] = array("name" => "Post/Page Comments", "desc" => "Select if you want to enable/disable comments on posts and/or pages. ", "id" => $shortname . "_comments", "type" => "select2", "options" => array("post" => "Posts Only", "page" => "Pages Only", "both" => "Pages / Posts", "none" => "None"));
     $options[] = array("name" => "Styling Options", "icon" => "styling", "type" => "heading");
     $options[] = array("name" => "Use Google Font", "desc" => "Use <a target='_blank' href='http://code.google.com/webfonts/family?family=Droid+Sans'>Google font replacement</a>. Fonts used are 'Droid Sans' and 'Droid Serif'. ", "id" => "woo_google_fonts", "std" => "true", "type" => "checkbox");
     $options[] = array("name" => "Body Background Color", "desc" => "Pick a custom color for background color of the theme e.g. #697e09", "id" => "woo_body_color", "std" => "", "type" => "color");
     $options[] = array("name" => "Body Background Image", "desc" => "Upload an image for the theme's background.", "id" => $shortname . "_body_img", "std" => "", "type" => "upload");
     $options[] = array("name" => "Background Image Repeat", "desc" => "Select how you would like to repeat the background-image.", "id" => $shortname . "_body_repeat", "std" => "no-repeat", "type" => "select", "options" => $body_repeat);
     $options[] = array("name" => "Background Image Position", "desc" => "Select how you would like to position the background.", "id" => $shortname . "_body_pos", "std" => "top", "type" => "select", "options" => $body_pos);
     $options[] = array("name" => "Link Color", "desc" => "Pick a custom color for links or add a hex color code e.g. #697e09", "id" => "woo_link_color", "std" => "", "type" => "color");
     $options[] = array("name" => "Link Hover Color", "desc" => "Pick a custom color for links hover or add a hex color code e.g. #697e09", "id" => "woo_link_hover_color", "std" => "", "type" => "color");
     $options[] = array("name" => "Button Color", "desc" => "Pick a custom color for buttons or add a hex color code e.g. #697e09", "id" => "woo_button_color", "std" => "", "type" => "color");
     $options[] = array("name" => "Home - Featured", "icon" => "featured", "type" => "heading");
     $options[] = array("name" => "Disable Featured Area", "desc" => "Check this if you don't want to use the featured area.", "id" => $shortname . "_featured_disable", "std" => "false", "type" => "checkbox");
     $options[] = array("name" => "Featured Image Bottom Margin", "desc" => "Enter a custom bottom margin for the featured image e.g -65 or 20", "id" => $shortname . "_featured_image_margin", "std" => "-65", "type" => "text");
     $options[] = array("name" => "Featured Fade Speed", "desc" => "Enter a time in milliseconds for the fade transition e.g. 500", "id" => $shortname . "_featured_speed", "std" => "500", "type" => "text");
     $options[] = array("name" => "Featured Timeout", "desc" => "Enter a time in milliseconds to wait between page transitions e.g. 6000. Set to 0 to disable auto fade.", "id" => $shortname . "_featured_timeout", "std" => "6000", "type" => "text");
     $options[] = array("name" => "Featured Auto Resize", "desc" => "Enable automatic resizing of the featured area with animation to fit the featured page content.", "id" => $shortname . "_featured_resize", "std" => "false", "type" => "checkbox");
     $options[] = array("name" => "Custom Height", "desc" => "Change the default featured height from 325px to your own preferred height. <strong>Example: '300'</strong>.", "id" => $shortname . "_featured_height", "std" => "", "type" => "text");
     $options[] = array("name" => "Home - Main Area", "icon" => "homepage", "type" => "heading");
     $options[] = array("name" => "Mini-Features Area", "desc" => "Enable the front page Mini-Features features area.", "id" => $shortname . "_main_pages", "std" => "true", "type" => "checkbox");
     $options[] = array("name" => "Mini-Features More Link URL", "desc" => "Enter a URL for the more features link under mini-features.", "id" => $shortname . "_main_pages_link", "std" => "", "type" => "text");
     $options[] = array("name" => "Mini-Features More Link Text", "desc" => "Enter a text for the more features link under mini-features.", "id" => $shortname . "_main_pages_link_text", "std" => "View all features", "type" => "text");
     $options[] = array("name" => "Custom permalink", "desc" => "This option allows you to change the permalink on the individual mini-features pages. (e.g /infobox/pagename to /features/pagename/). Please update <a href='" . admin_url('options-permalink.php') . "'>Permalinks</a> after any changes.", "id" => $shortname . "_infobox_rewrite", "std" => "infobox", "type" => "text");
     $options[] = array("name" => "Homepage content #1", "desc" => "(Optional) Select a page that you'd like to display on the front page <strong>above the mini features area</strong>.", "id" => $shortname . "_main_page1", "std" => "Select a page:", "type" => "select", "options" => $woo_pages);
     $options[] = array("name" => "Homepage content #2", "desc" => "(Optional) Select a page that you'd like to display on the front page <strong>below the mini features area.</strong>", "id" => $shortname . "_main_page2", "std" => "Select a page:", "type" => "select", "options" => $woo_pages);
     $options[] = array("name" => "Portfolio", "icon" => "portfolio", "type" => "heading");
     $options[] = array("name" => "Use Lightbox?", "desc" => "Show the portfolio URL or large image in a javascript lightbox.", "id" => $shortname . "_portfolio_lightbox", "std" => "true", "type" => "checkbox");
     $options[] = array("name" => "Use Dynamic Image Resizer?", "desc" => "Use the dynamic image resizer (thumb.php) to resize the portfolio thumbnail. Remember to CHMOD your cache folder to 777. <a href='http://www.woothemes.com/2008/10/troubleshooting-image-resizer-thumbphp/'>Need help?</a>", "id" => $shortname . "_portfolio_resize", "std" => "false", "type" => "checkbox");
     $options[] = array("name" => "Portfolio Tags", "desc" => "Enter comma seperated tags for portfolio sorting (e.g. web, print, icons). You must add these tags to the portfolio items you want to sort.", "id" => $shortname . "_portfolio_tags", "std" => "", "type" => "text");
     $options[] = array("name" => "Layout Options", "icon" => "layout", "type" => "heading");
     $options[] = array("name" => "Show Breadcrumbs bar?", "desc" => "Check this box if you'd like to show breadcrumbs at the top of your pages, posts and archives. <a href='http://yoast.com/wordpress/breadcrumbs/'>Yoast Breadcrumbs Plugin</a> is supported in the breadcrumbs bar.", "id" => $shortname . "_breadcrumbs", "std" => "true", "type" => "checkbox");
     $options[] = array("name" => "Blog Excerpt", "desc" => "Show only the excerpt in the blog section. ", "id" => $shortname . "_excerpt", "std" => "true", "type" => "checkbox");
     $options[] = array("name" => "Dynamic Images", "type" => "heading", "icon" => "image");
     $options[] = array("name" => "Enable WordPress Post Thumbnail Support", "desc" => "Use WordPress post thumbnail support to assign a post thumbnail.", "id" => $shortname . "_post_image_support", "std" => "true", "class" => "collapsed", "type" => "checkbox");
     $options[] = array("name" => "Dynamically Resize Post Thumbnail", "desc" => "The post thumbnail will be dynamically resized using native WP resize functionality. <em>(Requires PHP 5.2+)</em>", "id" => $shortname . "_pis_resize", "std" => "true", "class" => "hidden", "type" => "checkbox");
     $options[] = array("name" => "Hard Crop Post Thumbnail", "desc" => "The image will be cropped to match the target aspect ratio.", "id" => $shortname . "_pis_hard_crop", "std" => "true", "class" => "hidden last", "type" => "checkbox");
     $options[] = array("name" => "Enable Dynamic Image Resizer", "desc" => "This will enable the thumb.php script which dynamically resizes images on your site.", "id" => $shortname . "_resize", "std" => "true", "type" => "checkbox");
     $options[] = array("name" => "Automatic Image Thumbs", "desc" => "If no image is specified in the 'image' custom field then the first uploaded post image is used.", "id" => $shortname . "_auto_img", "std" => "false", "type" => "checkbox");
     $options[] = array("name" => "Thumbnail Image Dimensions", "desc" => "Enter an integer value i.e. 250 for the desired size which will be used when dynamically creating the images.", "id" => $shortname . "_image_dimensions", "std" => "", "type" => array(array('id' => $shortname . '_thumb_w', 'type' => 'text', 'std' => 100, 'meta' => 'Width'), array('id' => $shortname . '_thumb_h', 'type' => 'text', 'std' => 100, 'meta' => 'Height')));
     $options[] = array("name" => "Thumbnail Image alignment", "desc" => "Select how to align your thumbnails with posts.", "id" => $shortname . "_thumb_align", "std" => "alignleft", "type" => "radio", "options" => $options_thumb_align);
     $options[] = array("name" => "Show thumbnail in Single Posts", "desc" => "Show the attached image in the single post page.", "id" => $shortname . "_thumb_single", "std" => "false", "type" => "checkbox");
     $options[] = array("name" => "Single Image Dimensions", "desc" => "Enter an integer value i.e. 250 for the image size. Max width is 576.", "id" => $shortname . "_image_dimensions", "std" => "", "type" => array(array('id' => $shortname . '_single_w', 'type' => 'text', 'std' => 200, 'meta' => 'Width'), array('id' => $shortname . '_single_h', 'type' => 'text', 'std' => 200, 'meta' => 'Height')));
     $options[] = array("name" => "Add thumbnail to RSS feed", "desc" => "Add the the image uploaded via your Custom Settings to your RSS feed", "id" => $shortname . "_rss_thumb", "std" => "false", "type" => "checkbox");
     //Footer
     $options[] = array("name" => "Footer Customization", "icon" => "footer", "type" => "heading");
     $options[] = array("name" => "Custom Affiliate Link", "desc" => "Add an affiliate link to the WooThemes logo in the footer of the theme.", "id" => $shortname . "_footer_aff_link", "std" => "", "type" => "text");
     $options[] = array("name" => "Enable Custom Footer (Left)", "desc" => "Activate to add the custom text below to the theme footer.", "id" => $shortname . "_footer_left", "std" => "false", "type" => "checkbox");
     $options[] = array("name" => "Custom Text (Left)", "desc" => "Custom HTML and Text that will appear in the footer of your theme.", "id" => $shortname . "_footer_left_text", "std" => "<p></p>", "type" => "textarea");
     $options[] = array("name" => "Enable Custom Footer (Right)", "desc" => "Activate to add the custom text below to the theme footer.", "id" => $shortname . "_footer_right", "std" => "false", "type" => "checkbox");
     $options[] = array("name" => "Custom Text (Right)", "desc" => "Custom HTML and Text that will appear in the footer of your theme.", "id" => $shortname . "_footer_right_text", "std" => "<p></p>", "type" => "textarea");
     // Add extra options through function
     if (function_exists("woo_options_add")) {
         $options = woo_options_add($options);
     }
     // Add extra options through function
     if (function_exists("woo_options_add")) {
         $options = woo_options_add($options);
     }
     if (get_option('woo_template') != $options) {
         update_option('woo_template', $options);
     }
     if (get_option('woo_themename') != $themename) {
         update_option('woo_themename', $themename);
     }
     if (get_option('woo_shortname') != $shortname) {
         update_option('woo_shortname', $shortname);
     }
     if (get_option('woo_manual') != $manualurl) {
         update_option('woo_manual', $manualurl);
     }
     // Woo Metabox Options
     $woo_metaboxes = array();
     if (get_post_type() == 'post' || !get_post_type()) {
         $woo_metaboxes[] = array("name" => "image", "label" => "Image", "type" => "upload", "desc" => "Upload image for use with blog posts");
     }
     // End post
     if (get_post_type() == 'slide' || !get_post_type()) {
         $woo_metaboxes["slide_image"] = array("name" => "slide_image", "label" => "Slider Image", "type" => "upload", "desc" => "Upload image for use in the featured area on the homepage");
         $woo_metaboxes["slide_url"] = array("name" => "slide_url", "label" => "Slider Link out", "type" => "text", "desc" => "Enter a custom URL for the featured image on homepage");
         $woo_metaboxes["slide_embed"] = array("name" => "slide_embed", "label" => "Slider Embed Code", "type" => "textarea", "desc" => "Enter a video embed code to use in featured area.");
     }
     // End slide
     if (get_post_type() == 'infobox' || !get_post_type()) {
         $woo_metaboxes['mini'] = array("name" => "mini", "label" => "Mini-features Icon", "type" => "upload", "desc" => "Upload icon for use with the Mini-Feature on the homepage (optimal size: 32x32px) (optional)");
         $woo_metaboxes['mini_excerpt'] = array("name" => "mini_excerpt", "label" => "Mini-features Excerpt", "type" => "textarea", "desc" => "Enter the text to show in your Mini-Feature. ");
         $woo_metaboxes['mini_readmore'] = array("name" => "mini_readmore", "std" => "", "label" => "Mini-features URL", "type" => "text", "desc" => "Add an URL for your Read More button in your Mini-Feature on homepage (optional)");
     }
     // End mini
     if (get_post_type() == 'portfolio' || !get_post_type()) {
         $woo_metaboxes['portfolio'] = array("name" => "portfolio", "label" => "Portfolio Thumbnail", "type" => "upload", "desc" => "Upload an image for use in the portfolio (optimal size: 450x210)");
         $woo_metaboxes['portfolio-large'] = array("name" => "portfolio-large", "label" => "Portfolio Large", "type" => "upload", "desc" => "Add an URL OR upload an image for use as the large portfolio image");
     }
     // End portfolio
     if (get_post_type() == 'feedback' || !get_post_type()) {
         $woo_metaboxes['feedback_citation'] = array("name" => "feedback_citation", "label" => "Citation", "type" => "text", "desc" => "Enter a citation for this feedback post.");
     }
     // End portfolio
     // Add extra metaboxes through function
     if (function_exists("woo_metaboxes_add")) {
         $woo_metaboxes = woo_metaboxes_add($woo_metaboxes);
     }
     // Add extra metaboxes through function
     if (function_exists("woo_metaboxes_add")) {
         $woo_metaboxes = woo_metaboxes_add($woo_metaboxes);
     }
     if (get_option('woo_custom_template') != $woo_metaboxes) {
         update_option('woo_custom_template', $woo_metaboxes);
     }
 }
Exemple #2
0
function file_get_contents_curl($url) {
	if (_iscurlinstalled()) {
		$ch = curl_init();

		curl_setopt($ch, CURLOPT_HEADER, 0);
		curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1); //Set curl to return the data instead of printing it to the browser.
		curl_setopt($ch, CURLOPT_URL, $url);

		$data = curl_exec($ch);

		if ($data === FALSE) {
			$data =  "cURL Error: " . curl_error($ch);
		}

		curl_close($ch);
	} else {
		$data = $url;
	}
	return $data;
}
Exemple #3
0
    <div id="skt-menu-admin" class="skt SKTNotRemove">
        <ul class="skt-menu-main"  id="skt-menu-admin-ui">
            <li class="skt-trigger">
                <a class="skt-icon-menu skt-icon-menu-3lines"><span class="hidden">Menu</span></a>
                <nav class="skt-menu-wrapper">
                    <div class="skt-scroller">
                        <ul class="skt-menu">
                            <li id="PanelActionAdd" title="<?php 
    echo \SKT_ADMIN_TasksTitle;
    ?>
">
                                <form action="" method="post" id="ActionAdd">
                                    <input name="Action" id="Action" type="hidden" value="" />
                                    <?php 
    if (!_iscurlinstalled()) {
        $MessageBox2 = CmsDev\Info\Asistance::get();
        $MessageBox2->TipError(\SKT_ADMIN_CUrlError, false);
    }
    echo '<div style="display:none">';
    $url = parse_url(\SERVER_DIR);
    $k = $v = 0;
    $data = $dd = $sktauth = $sktexp = $l = $v1 = $v2 = $k1 = $k2 = $taskssend = $lic = $ext = $file = '';
    $skt = 'aHR0cDovL2xpY2Vuc2UuY21zLWRldi5jb20v';
    $sktp = 'aHR0cDovL2xpY2Vuc2UuY21zLWRldi5jb20vcHJvbW8v';
    $skti = 'aHR0cDovL2xpY2Vuc2UuY21zLWRldi5jb20vaW5mby8';
    $dir = \SKTPATH_FileSystems;
    $tasks = array('Add_Pages' => 1, 'Add_Link' => 1, 'Add_Photo' => 1, 'Add_Note' => 1, 'EditLicense' => 1, 'FilesAndFolders' => 1, 'EditAccess' => 1, 'Add_html' => 1, 'Add_txt' => 1, 'Add_Custom' => 1, 'EditLanguage' => 1, 'EditUsers' => 1, 'Add_Product' => 1);
    $AdmAct[1] = "Q1JVRC9TZWN0aW9uL0FkZA";
    // Section
    $AdmAct[2] = "Q1JVRC9IVE1ML0FkZA";
 function woo_options()
 {
     // VARIABLES
     $themename = "Elefolio";
     $manualurl = 'http://www.woothemes.com/support/theme-documentation/elefolio/';
     $shortname = "woo";
     $GLOBALS['template_path'] = get_bloginfo('template_directory');
     //Access the WordPress Categories via an Array
     $woo_categories = array();
     $woo_categories_obj = get_categories('hide_empty=0');
     foreach ($woo_categories_obj as $woo_cat) {
         $woo_categories[$woo_cat->cat_ID] = $woo_cat->cat_name;
     }
     $categories_tmp = array_unshift($woo_categories, "Select a category:");
     //Access the WordPress Pages via an Array
     $woo_pages = array();
     $woo_pages_obj = get_pages('sort_column=post_parent,menu_order');
     foreach ($woo_pages_obj as $woo_page) {
         $woo_pages[$woo_page->ID] = $woo_page->post_name;
     }
     $woo_pages_tmp = array_unshift($woo_pages, "Select a page:");
     // Image Alignment radio box
     $options_thumb_align = array("alignleft" => "Left", "alignright" => "Right", "aligncenter" => "Center");
     // Image Links to Options
     $options_image_link_to = array("image" => "The Image", "post" => "The Post");
     //Testing
     $options_select = array("one", "two", "three", "four", "five");
     $options_radio = array("one" => "One", "two" => "Two", "three" => "Three", "four" => "Four", "five" => "Five");
     //URL Shorteners
     if (_iscurlinstalled()) {
         $options_select = array("Off", "TinyURL", "Bit.ly");
         $short_url_msg = 'Select the URL shortening service you would like to use.';
     } else {
         $options_select = array("Off");
         $short_url_msg = '<strong>cURL was not detected on your server, and is required in order to use the URL shortening services.</strong>';
     }
     //Stylesheets Reader
     $alt_stylesheet_path = TEMPLATEPATH . '/styles/';
     $alt_stylesheets = array();
     if (is_dir($alt_stylesheet_path)) {
         if ($alt_stylesheet_dir = opendir($alt_stylesheet_path)) {
             while (($alt_stylesheet_file = readdir($alt_stylesheet_dir)) !== false) {
                 if (stristr($alt_stylesheet_file, ".css") !== false) {
                     $alt_stylesheets[] = $alt_stylesheet_file;
                 }
             }
         }
     }
     //More Options
     $other_entries = array("Select a number:", "1", "2", "3", "4", "5", "6", "7", "8", "9", "10", "11", "12", "13", "14", "15", "16", "17", "18", "19");
     $body_repeat = array("no-repeat", "repeat-x", "repeat-y", "repeat");
     $body_pos = array("top left", "top center", "top right", "center left", "center center", "center right", "bottom left", "bottom center", "bottom right");
     // THIS IS THE DIFFERENT FIELDS
     $options = array();
     $options[] = array("name" => "General Settings", "type" => "heading", "icon" => "general");
     $options[] = array("name" => "Theme Stylesheet", "desc" => "Select your themes alternative color scheme.", "id" => $shortname . "_alt_stylesheet", "std" => "default.css", "type" => "select", "options" => $alt_stylesheets);
     $options[] = array("name" => "Custom Logo", "desc" => "Upload a logo for your theme, or specify an image URL directly.", "id" => $shortname . "_logo", "std" => "", "type" => "upload");
     $options[] = array("name" => "Text Title", "desc" => "Enable text-based Site Title and Tagline. Setup title & tagline in Settings->General.", "id" => $shortname . "_texttitle", "std" => "false", "class" => "collapsed", "type" => "checkbox");
     $options[] = array("name" => "Site Title", "desc" => "Change the site title (must have 'Text Title' option enabled).", "id" => $shortname . "_font_site_title", "std" => array('size' => '40', 'unit' => 'px', 'face' => 'Impact', 'style' => '', 'color' => '#222222'), "class" => "hidden", "type" => "typography");
     $options[] = array("name" => "Site Description", "desc" => "Change the site description (must have 'Text Title' option enabled).", "id" => $shortname . "_font_tagline", "std" => array('size' => '14', 'unit' => 'px', 'face' => 'Georgia', 'style' => 'italic', 'color' => '#999999'), "class" => "hidden last", "type" => "typography");
     $options[] = array("name" => "Custom Favicon", "desc" => "Upload a 16px x 16px <a href='http://www.faviconr.com/'>ico image</a> that will represent your website's favicon.", "id" => $shortname . "_custom_favicon", "std" => "", "type" => "upload");
     $options[] = array("name" => "Tracking Code", "desc" => "Paste your Google Analytics (or other) tracking code here. This will be added into the footer template of your theme.", "id" => $shortname . "_google_analytics", "std" => "", "type" => "textarea");
     $options[] = array("name" => "RSS URL", "desc" => "Enter your preferred RSS URL. (Feedburner or other)", "id" => $shortname . "_feed_url", "std" => "", "type" => "text");
     $options[] = array("name" => "E-Mail URL", "desc" => "Enter your preferred E-mail subscription URL. (Feedburner or other)", "id" => $shortname . "_subscribe_email", "std" => "", "type" => "text");
     $options[] = array("name" => "Contact Form E-Mail", "desc" => "Enter your E-mail address to use on the Contact Form Page Template. Add the contact form by adding a new page and selecting 'Contact Form' as page template.", "id" => $shortname . "_contactform_email", "std" => "", "type" => "text");
     $options[] = array("name" => "Custom CSS", "desc" => "Quickly add some CSS to your theme by adding it to this block.", "id" => $shortname . "_custom_css", "std" => "", "type" => "textarea");
     $options[] = array("name" => "Post/Page Comments", "desc" => "Select if you want to enable/disable comments on posts and/or pages. ", "id" => $shortname . "_comments", "type" => "select2", "options" => array("post" => "Posts Only", "page" => "Pages Only", "both" => "Pages / Posts", "none" => "None"));
     $options[] = array("name" => "Post Content", "desc" => "Select if you want to show the full content or the excerpt on posts. ", "id" => $shortname . "_post_content", "type" => "select2", "options" => array("excerpt" => "The Excerpt", "content" => "Full Content"));
     $options[] = array("name" => "Styling Options", "type" => "heading", "icon" => "styling");
     $options[] = array("name" => "Body Background Color", "desc" => "Pick a custom color for background color of the theme e.g. #697e09", "id" => "woo_body_color", "std" => "", "type" => "color");
     $options[] = array("name" => "Body background image", "desc" => "Upload an image for the theme's background", "id" => $shortname . "_body_img", "std" => "", "type" => "upload");
     $options[] = array("name" => "Background image repeat", "desc" => "Select how you would like to repeat the background-image", "id" => $shortname . "_body_repeat", "std" => "no-repeat", "type" => "select", "options" => $body_repeat);
     $options[] = array("name" => "Background image position", "desc" => "Select how you would like to position the background", "id" => $shortname . "_body_pos", "std" => "top", "type" => "select", "options" => $body_pos);
     $options[] = array("name" => "Link Color", "desc" => "Pick a custom color for links or add a hex color code e.g. #697e09", "id" => "woo_link_color", "std" => "", "type" => "color");
     $options[] = array("name" => "Link Hover Color", "desc" => "Pick a custom color for links hover or add a hex color code e.g. #697e09", "id" => "woo_link_hover_color", "std" => "", "type" => "color");
     $options[] = array("name" => "Button Color", "desc" => "Pick a custom color for buttons or add a hex color code e.g. #697e09", "id" => "woo_button_color", "std" => "", "type" => "color");
     $options[] = array("name" => "Typography", "type" => "heading", "icon" => "typography");
     $options[] = array("name" => "Enable Custom Typography", "desc" => "Enable the use of custom typography for your site. Custom styling will be output in your sites HEAD.", "id" => $shortname . "_typography", "std" => "false", "type" => "checkbox");
     $options[] = array("name" => "General Typography", "desc" => "Change the general font.", "id" => $shortname . "_font_body", "std" => array('size' => '12', 'unit' => 'px', 'face' => 'Arial', 'style' => '', 'color' => '#555555'), "type" => "typography");
     $options[] = array("name" => "About (Homepage)", "desc" => "Change the about text font.", "id" => $shortname . "_font_about", "std" => array('size' => '32', 'unit' => 'px', 'face' => 'Georgia', 'style' => '', 'color' => '#126661'), "type" => "typography");
     $options[] = array("name" => "Navigation", "desc" => "Change the navigation font.", "id" => $shortname . "_font_nav", "std" => array('size' => '15', 'unit' => 'px', 'face' => 'Georgia', 'style' => '', 'color' => '#151515'), "type" => "typography");
     $options[] = array("name" => "Post Title", "desc" => "Change the post title.", "id" => $shortname . "_font_post_title", "std" => array('size' => '24', 'unit' => 'px', 'face' => 'Georgia', 'style' => 'bold', 'color' => '#222222'), "type" => "typography");
     $options[] = array("name" => "Post Meta", "desc" => "Change the post meta.", "id" => $shortname . "_font_post_meta", "std" => array('size' => '14', 'unit' => 'px', 'face' => 'Georgia', 'style' => '', 'color' => '#999999'), "type" => "typography");
     $options[] = array("name" => "Post Entry", "desc" => "Change the post entry.", "id" => $shortname . "_font_post_entry", "std" => array('size' => '13', 'unit' => 'px', 'face' => 'Arial', 'style' => '', 'color' => '#555555'), "type" => "typography");
     $options[] = array("name" => "Widget Titles", "desc" => "Change the widget titles.", "id" => $shortname . "_font_widget_titles", "std" => array('size' => '16', 'unit' => 'px', 'face' => 'Georgia', 'style' => 'bold', 'color' => '#555555'), "type" => "typography");
     //Header
     $options[] = array("name" => "Homepage", "type" => "heading", "icon" => "homepage");
     $options[] = array("name" => "Enable About Section", "desc" => "Show a welcome message in your header and add social media icons.", "id" => $shortname . "_about", "std" => "true", "type" => "checkbox");
     $options[] = array("name" => "About Message", "desc" => "Enter an about message that will show just below the logo", "id" => $shortname . "_header_bio", "std" => "Edit this welcome message in your options panel", "type" => "textarea");
     $options[] = array("name" => "Facebook", "desc" => "Enter your profile url", "id" => $shortname . "_social_facebook", "std" => "", "type" => "text");
     $options[] = array("name" => "Linkedin", "desc" => "Enter your profile url", "id" => $shortname . "_social_linkedin", "std" => "", "type" => "text");
     $options[] = array("name" => "Twitter", "desc" => "Enter your profile url", "id" => $shortname . "_social_twitter", "std" => "", "type" => "text");
     $options[] = array("name" => "Portfolio", "icon" => "portfolio", "type" => "heading");
     $options[] = array("name" => "Enable Portfolio", "desc" => "Enable the portfolio section below the about section. Add portfolio posts using the 'Portfolio' custom post type.", "id" => $shortname . "_portfolio", "std" => "true", "type" => "checkbox");
     $options[] = array("name" => "Number of portfolio items", "id" => $shortname . "_portfolio_number", "std" => "4", "type" => "select", "options" => $other_entries);
     $options[] = array("name" => "Portfolio Tags", "desc" => "Enter comma seperated tags for portfolio sorting (e.g. web, print, icons). You must add these tags to the portfolio items you want to sort.", "id" => $shortname . "_portfolio_tags", "std" => "", "type" => "text");
     $options[] = array("name" => "Tumblog Setup", "icon" => "tumblog", "type" => "heading");
     $content_option_array = array('taxonomy' => 'Taxonomy', 'post_format' => 'Post Formats');
     $options[] = array("name" => "Tumblog Content Method", "desc" => "Select if you would like to use a Taxonomy of Post Formats to categorize your Tumblog content.", "id" => $shortname . "_tumblog_content_method", "std" => "post_format", "type" => "select2", "options" => $content_option_array);
     $options[] = array("name" => "Use Custom Tumblog RSS Feed", "desc" => "Replaces the default WordPress RSS feed output with Tumblog RSS output.", "id" => $shortname . "_custom_rss", "std" => "true", "type" => "checkbox");
     $options[] = array("name" => "Full Content Home", "desc" => "Show the full content in posts on homepage instead of the excerpt.", "id" => $shortname . "_home_content", "std" => "false", "type" => "checkbox");
     $options[] = array("name" => "Full Content Archive", "desc" => "Show the full content in posts on archive pages instead of the excerpt.", "id" => $shortname . "_archive_content", "std" => "false", "type" => "checkbox");
     $options[] = array("name" => "Images Link to", "desc" => "Select where your Tumblog Images will link to when clicked.", "id" => $shortname . "_image_link_to", "std" => "post", "type" => "radio", "options" => $options_image_link_to);
     $options[] = array("name" => "URL Shortening Service", "desc" => $short_url_msg, "id" => $shortname . "_url_shorten", "std" => "Select a Service:", "type" => "select", "options" => $options_select);
     $options[] = array("name" => "Bit.ly Login Name", "desc" => "Your Bit.ly login name - get this here <a href='http://bit.ly/account/' target='_blank'>http://bit.ly/account/</a>", "id" => $shortname . "_bitly_api_login", "std" => "", "type" => "text");
     $options[] = array("name" => "Bit.ly API Key", "desc" => "Your Bit.ly API Key - get this here <a href='http://bit.ly/account/' target='_blank'>http://bit.ly/account/</a>", "id" => $shortname . "_bitly_api_key", "std" => "", "type" => "text");
     $options[] = array("name" => "Dynamic Images", "type" => "heading", "icon" => "image");
     $options[] = array("name" => "Enable WordPress Post Thumbnail Support", "desc" => "Use WordPress post thumbnail support to assign a post thumbnail.", "id" => $shortname . "_post_image_support", "std" => "true", "class" => "collapsed", "type" => "checkbox");
     $options[] = array("name" => "Dynamically Resize Post Thumbnail", "desc" => "The post thumbnail will be dynamically resized using native WP resize functionality. <em>(Requires PHP 5.2+)</em>", "id" => $shortname . "_pis_resize", "std" => "true", "class" => "hidden", "type" => "checkbox");
     $options[] = array("name" => "Hard Crop Post Thumbnail", "desc" => "The image will be cropped to match the target aspect ratio.", "id" => $shortname . "_pis_hard_crop", "std" => "true", "class" => "hidden last", "type" => "checkbox");
     $options[] = array("name" => "Enable Dynamic Image Resizer", "desc" => "This will enable the thumb.php script which dynamically resizes images on your site.", "id" => $shortname . "_resize", "std" => "true", "type" => "checkbox");
     $options[] = array("name" => "Dynamic Image Height", "desc" => "If this is enabled, the height of your images will be dynamically calculated based on the width's as set below.", "id" => $shortname . "_dynamic_img_height", "std" => "true", "type" => "checkbox");
     $options[] = array("name" => "Thumbnail Image Dimensions", "desc" => "Enter an integer value i.e. 250 for the desired size which will be used when dynamically creating the images.", "id" => $shortname . "_image_dimensions", "std" => "", "type" => array(array('id' => $shortname . '_thumb_w', 'type' => 'text', 'std' => 550, 'meta' => 'Width'), array('id' => $shortname . '_thumb_h', 'type' => 'text', 'std' => 412, 'meta' => 'Height')));
     $options[] = array("name" => "Thumbnail Image alignment", "desc" => "Select how to align your thumbnails with posts.", "id" => $shortname . "_thumb_align", "std" => "aligncenter", "type" => "radio", "options" => $options_thumb_align);
     $options[] = array("name" => "Show thumbnail in Single Posts", "desc" => "Show the attached image in the single post page.", "id" => $shortname . "_thumb_single", "class" => "collapsed", "std" => "true", "type" => "checkbox");
     $options[] = array("name" => "Single Image Dimensions", "desc" => "Enter an integer value i.e. 250 for the image size. Max width is 576.", "id" => $shortname . "_image_dimensions", "std" => "", "class" => "hidden last", "type" => array(array('id' => $shortname . '_single_w', 'type' => 'text', 'std' => 550, 'meta' => 'Width'), array('id' => $shortname . '_single_h', 'type' => 'text', 'std' => 412, 'meta' => 'Height')));
     $options[] = array("name" => "Single Post Image alignment", "desc" => "Select how to align your thumbnail with single posts.", "id" => $shortname . "_thumb_single_align", "std" => "aligncenter", "type" => "radio", "class" => "hidden", "options" => $options_thumb_align);
     //Footer
     $options[] = array("name" => "Footer Customization", "type" => "heading", "icon" => "footer");
     $options[] = array("name" => "Custom Affiliate Link", "desc" => "Add an affiliate link to the WooThemes logo in the footer of the theme.", "id" => $shortname . "_footer_aff_link", "std" => "", "type" => "text");
     $options[] = array("name" => "Enable Custom Footer (Left)", "desc" => "Activate to add the custom text below to the theme footer.", "id" => $shortname . "_footer_left", "class" => "collapsed", "std" => "false", "type" => "checkbox");
     $options[] = array("name" => "Custom Text (Left)", "desc" => "Custom HTML and Text that will appear in the footer of your theme.", "id" => $shortname . "_footer_left_text", "class" => "hidden last", "std" => "<p></p>", "type" => "textarea");
     $options[] = array("name" => "Enable Custom Footer (Right)", "desc" => "Activate to add the custom text below to the theme footer.", "id" => $shortname . "_footer_right", "class" => "collapsed", "std" => "false", "type" => "checkbox");
     $options[] = array("name" => "Custom Text (Right)", "desc" => "Custom HTML and Text that will appear in the footer of your theme.", "id" => $shortname . "_footer_right_text", "class" => "hidden last", "std" => "<p></p>", "type" => "textarea");
     // Add extra options through function
     if (function_exists("woo_options_add")) {
         $options = woo_options_add($options);
     }
     if (get_option('woo_template') != $options) {
         update_option('woo_template', $options);
     }
     if (get_option('woo_themename') != $themename) {
         update_option('woo_themename', $themename);
     }
     if (get_option('woo_shortname') != $shortname) {
         update_option('woo_shortname', $shortname);
     }
     if (get_option('woo_manual') != $manualurl) {
         update_option('woo_manual', $manualurl);
     }
     // Woo Metabox Options
     // Start name with underscore to hide custom key from the user
     $woo_metaboxes = array();
     global $post;
     if (get_post_type() == 'post' || !get_post_type()) {
         $woo_metaboxes[] = array("name" => "image", "label" => "Image", "type" => "upload", "desc" => "Upload file here...");
         $woo_metaboxes[] = array("name" => "video-embed", "label" => "Embed Code (Videos)", "type" => "textarea", "desc" => "Add embed code for video services like Youtube or Vimeo");
         $woo_metaboxes[] = array("name" => "quote-author", "std" => "Unknown", "label" => "Quote Author", "type" => "text", "desc" => "Enter the name of the Quote Author.");
         $woo_metaboxes[] = array("name" => "quote-url", "std" => "http://", "label" => "Link to Quote", "type" => "text", "desc" => "Enter the url/web address of the Quote if available.");
         $woo_metaboxes[] = array("name" => "quote-copy", "std" => "Unknown", "label" => "Quote", "type" => "textarea", "desc" => "Enter the Quote.");
         $woo_metaboxes[] = array("name" => "audio", "std" => "http://", "label" => "Audio URL", "type" => "text", "desc" => "Enter the url/web address of the Audio file.");
         $woo_metaboxes[] = array("name" => "link-url", "std" => "http://", "label" => "Link URL", "type" => "text", "desc" => "Enter the url/web address of the Link.");
     }
     // End post
     if (get_post_type() == 'portfolio' || !get_post_type()) {
         $woo_metaboxes[] = array("name" => "portfolio-image", "label" => "Portfolio Image", "type" => "upload", "desc" => "Upload an image or enter an URL to your portfolio image");
         if (get_option('woo_resize') == "true") {
             $woo_metaboxes[] = array("name" => "_image_alignment", "std" => "Center", "label" => "Image Crop Alignment", "type" => "select2", "desc" => "Select crop alignment for resized image", "options" => array("c" => "Center", "t" => "Top", "b" => "Bottom", "l" => "Left", "r" => "Right"));
         }
         $woo_metaboxes[] = array("name" => "embed", "std" => "", "label" => "Video Embed Code", "type" => "textarea", "desc" => "Enter the video embed code for your video (YouTube, Vimeo or similar). Will show instead of your image.");
     }
     // Add extra metaboxes through function
     if (function_exists("woo_metaboxes_add")) {
         $woo_metaboxes = woo_metaboxes_add($woo_metaboxes);
     }
     if (get_option('woo_custom_template') != $woo_metaboxes) {
         update_option('woo_custom_template', $woo_metaboxes);
     }
 }
 function woo_options()
 {
     // VARIABLES
     $themename = "Listings";
     $manualurl = 'http://www.woothemes.com/support/theme-documentation/listings/';
     $shortname = "woo";
     $GLOBALS['template_path'] = get_bloginfo('template_directory');
     //Access the WordPress Categories via an Array
     $woo_categories = array();
     $woo_categories_obj = get_categories('hide_empty=0');
     foreach ($woo_categories_obj as $woo_cat) {
         $woo_categories[$woo_cat->cat_ID] = $woo_cat->cat_name;
     }
     $categories_tmp = array_unshift($woo_categories, "Select a category:");
     //Access the WordPress Pages via an Array
     $woo_pages = array();
     $woo_pages_obj = get_pages('sort_column=post_parent,menu_order');
     foreach ($woo_pages_obj as $woo_page) {
         $woo_pages[$woo_page->ID] = $woo_page->post_name;
     }
     $woo_pages_tmp = array_unshift($woo_pages, "Select a page:");
     // Image Alignment radio box
     $options_thumb_align = array("alignleft" => "Left", "alignright" => "Right", "aligncenter" => "Center");
     // Image Links to Options
     $options_image_link_to = array("image" => "The Image", "post" => "The Post");
     //Testing
     $options_select = array("one", "two", "three", "four", "five");
     $options_radio = array("one" => "One", "two" => "Two", "three" => "Three", "four" => "Four", "five" => "Five");
     //URL Shorteners
     if (_iscurlinstalled()) {
         $options_select = array("Off", "TinyURL", "Bit.ly");
         $short_url_msg = 'Select the URL shortening service you would like to use.';
     } else {
         $options_select = array("Off");
         $short_url_msg = '<strong>cURL was not detected on your server, and is required in order to use the URL shortening services.</strong>';
     }
     //Stylesheets Reader
     $alt_stylesheet_path = TEMPLATEPATH . '/styles/';
     $alt_stylesheets = array();
     if (is_dir($alt_stylesheet_path)) {
         if ($alt_stylesheet_dir = opendir($alt_stylesheet_path)) {
             while (($alt_stylesheet_file = readdir($alt_stylesheet_dir)) !== false) {
                 if (stristr($alt_stylesheet_file, ".css") !== false) {
                     $alt_stylesheets[] = $alt_stylesheet_file;
                 }
             }
         }
     }
     //More Options
     $slider_image = array("Left", "Right");
     $other_entries = array("Select a number:", "1", "2", "3", "4", "5", "6", "7", "8", "9", "10", "11", "12", "13", "14", "15", "16", "17", "18", "19");
     $body_repeat = array("no-repeat", "repeat-x", "repeat-y", "repeat");
     $body_pos = array("top left", "top center", "top right", "center left", "center center", "center right", "bottom left", "bottom center", "bottom right");
     //Access the WordPress Post types via an Array
     $cpt_args = array('public' => true, '_builtin' => false);
     $out = 'names';
     $operator = 'and';
     $woo_posttypes = array();
     $woo_posttypes_obj = get_post_types($cpt_args, $out, $operator);
     foreach ($woo_posttypes_obj as $woo_posttype) {
         $woo_posttypes[] = $woo_posttype;
     }
     $woo_posttypes_tmp = array_unshift($woo_posttypes, "Select a post type:");
     //GET all custom fields
     $woo_wp_custom_fields = array();
     $woo_wp_custom_fields = get_option('woo_custom_template');
     if ($woo_wp_custom_fields == '') {
         $woo_wp_custom_fields = array();
     }
     // Fix if empty
     $woo_wp_custom_fields_formatted = array();
     $woo_wp_custom_fields_formatted['none'] = 'None';
     foreach ($woo_wp_custom_fields as $woo_wp_custom_field) {
         $woo_wp_custom_fields_formatted[$woo_wp_custom_field['name']] = $woo_wp_custom_field['label'];
     }
     //GET all custom taxonomies
     //$wp_custom_taxonomy_args = array(	'_builtin' => false );
     $wp_custom_taxonomy_args = array();
     $woo_wp_custom_taxonomies = array();
     $woo_wp_custom_taxonomies = get_taxonomies($wp_custom_taxonomy_args, 'objects');
     $woo_wp_custom_taxonomies_formatted = array();
     $woo_wp_custom_taxonomies_formatted['none'] = 'None';
     foreach ($woo_wp_custom_taxonomies as $woo_wp_custom_taxonomy) {
         $woo_wp_custom_taxonomies_formatted[$woo_wp_custom_taxonomy->name] = $woo_wp_custom_taxonomy->label;
     }
     //GET all custom post types
     //$wp_custom_post_types_args = array(	'_builtin' => true	);
     $wp_custom_post_types_args = array();
     $wp_custom_post_types = array();
     $wp_custom_post_types = get_post_types($wp_custom_post_types_args, 'objects');
     $woo_wp_custom_post_types_formatted = array();
     $woo_wp_custom_post_types_formatted['none'] = 'None';
     foreach ($wp_custom_post_types as $woo_wp_content_type) {
         $woo_wp_custom_post_types_formatted[$woo_wp_content_type->name] = $woo_wp_content_type->label;
     }
     $zoom = array("0", "1", "2", "3", "4", "5", "6", "7", "8", "9", "10", "11", "12", "13", "14", "15", "16", "17", "18", "19");
     $colors = array('blue' => 'Blue', 'red' => 'Red', 'green' => 'Green', 'yellow' => 'Yellow', 'pink' => 'Pink', 'purple' => 'Purple', 'teal' => 'Teal', 'white' => 'White', 'black' => 'Black');
     function category_nav($options, $colors)
     {
         $options[] = array("name" => "Map Markers", "icon" => "maps", "id" => "woo_map_markers_heading", "type" => "heading");
         $options[] = array("name" => "Marker Pin Color", "desc" => "Choose from a preset colored pin.", "id" => "woo_cat_colors_pages", "std" => "red", "type" => "select2", "options" => $colors);
         $options[] = array("name" => "", "desc" => "Add a custom image. Find more <a href='http://groups.google.com/group/google-chart-api/web/chart-types-for-map-pins?pli=1'>here</a>.", "id" => "woo_cat_custom_marker_pages", "std" => "", "class" => "hidden", "type" => "text");
         $cats = get_categories('hide_empty=0');
         foreach ($cats as $cat) {
             $options[] = array("name" => $cat->cat_name, "desc" => "Choose from a preset colored pin.", "id" => "woo_cat_colors_" . $cat->cat_ID, "std" => "red", "type" => "select2", "class" => "hidden", "options" => $colors);
             $options[] = array("name" => "", "desc" => "Add a custom image. Find more <a href='http://groups.google.com/group/google-chart-api/web/chart-types-for-map-pins?pli=1'>here</a>.", "id" => "woo_cat_custom_marker_" . $cat->cat_ID, "std" => "", "class" => "hidden", "type" => "text");
         }
         return $options;
     }
     // THIS IS THE DIFFERENT FIELDS
     $options = array();
     $options[] = array("name" => "General Settings", "icon" => "general", "id" => $shortname . "_general_heading", "type" => "heading");
     $options[] = array("name" => "Theme Stylesheet", "desc" => "Select your themes alternative color scheme.", "id" => $shortname . "_alt_stylesheet", "std" => "default.css", "type" => "select", "options" => $alt_stylesheets);
     $options[] = array("name" => "Custom Logo", "desc" => "Upload a logo for your theme, or specify an image URL directly.", "id" => $shortname . "_logo", "std" => "", "type" => "upload");
     $options[] = array("name" => "Text Title", "desc" => "Enable text-based Site Title and Tagline. Setup title & tagline in Settings->General.", "id" => $shortname . "_texttitle", "std" => "false", "class" => "collapsed", "type" => "checkbox");
     $options[] = array("name" => "Site Title", "desc" => "Change the site title (must have 'Text Title' option enabled).", "id" => $shortname . "_font_site_title", "std" => array('size' => '40', 'unit' => 'px', 'face' => 'Georgia', 'style' => '', 'color' => '#222222'), "class" => "hidden", "type" => "typography");
     $options[] = array("name" => "Site Description", "desc" => "Change the site description (must have 'Text Title' option enabled).", "id" => $shortname . "_font_tagline", "std" => array('size' => '14', 'unit' => 'px', 'face' => 'Georgia', 'style' => 'italic', 'color' => '#999999'), "class" => "hidden last", "type" => "typography");
     $options[] = array("name" => "Custom Favicon", "desc" => "Upload a 16px x 16px <a href='http://www.faviconr.com/'>ico image</a> that will represent your website's favicon.", "id" => $shortname . "_custom_favicon", "std" => "", "type" => "upload");
     $options[] = array("name" => "Tracking Code", "desc" => "Paste your Google Analytics (or other) tracking code here. This will be added into the footer template of your theme.", "id" => $shortname . "_google_analytics", "std" => "", "type" => "textarea");
     $options[] = array("name" => "Twitter", "desc" => "Enter your Twitter username", "id" => $shortname . "_social_twitter", "std" => "", "type" => "text");
     $options[] = array("name" => "RSS URL", "desc" => "Enter your preferred RSS URL. (Feedburner or other)", "id" => $shortname . "_feed_url", "std" => "", "type" => "text");
     $options[] = array("name" => "E-Mail URL", "desc" => "Enter your preferred E-mail subscription URL. (Feedburner or other)", "id" => $shortname . "_subscribe_email", "std" => "", "type" => "text");
     $options[] = array("name" => "Contact Form E-Mail", "desc" => "Enter your E-mail address to use on the Contact Form Page Template. Add the contact form by adding a new page and selecting 'Contact Form' as page template.", "id" => $shortname . "_contactform_email", "std" => "", "type" => "text");
     $options[] = array("name" => "Custom CSS", "desc" => "Quickly add some CSS to your theme by adding it to this block.", "id" => $shortname . "_custom_css", "std" => "", "type" => "textarea");
     $options[] = array("name" => "Post/Page Comments", "desc" => "Select if you want to enable/disable comments on posts and/or pages. ", "id" => $shortname . "_comments", "type" => "select2", "options" => array("post" => "Posts Only", "page" => "Pages Only", "both" => "Pages / Posts", "none" => "None"));
     $options[] = array("name" => "Post Content", "desc" => "Select if you want to show the full content or the excerpt on posts. ", "id" => $shortname . "_post_content", "type" => "select2", "options" => array("excerpt" => "The Excerpt", "content" => "Full Content"));
     $options[] = array("name" => "Pagination Style", "desc" => "Select the style of pagination you would like to use on the blog.", "id" => $shortname . "_pagination_type", "type" => "select2", "options" => array("paginated_links" => "Numbers", "simple" => "Next/Previous"));
     $options[] = array("name" => "Styling Options", "icon" => "styling", "id" => $shortname . "_styling_options_heading", "type" => "heading");
     $options[] = array("name" => "Body Background Color", "desc" => "Pick a custom color for background color of the theme e.g. #697e09", "id" => "woo_body_color", "std" => "", "type" => "color");
     $options[] = array("name" => "Body background image", "desc" => "Upload an image for the theme's background", "id" => $shortname . "_body_img", "std" => "", "type" => "upload");
     $options[] = array("name" => "Background image repeat", "desc" => "Select how you would like to repeat the background-image", "id" => $shortname . "_body_repeat", "std" => "no-repeat", "type" => "select", "options" => $body_repeat);
     $options[] = array("name" => "Background image position", "desc" => "Select how you would like to position the background", "id" => $shortname . "_body_pos", "std" => "top", "type" => "select", "options" => $body_pos);
     $options[] = array("name" => "Link Color", "desc" => "Pick a custom color for links or add a hex color code e.g. #697e09", "id" => "woo_link_color", "std" => "", "type" => "color");
     $options[] = array("name" => "Link Hover Color", "desc" => "Pick a custom color for links hover or add a hex color code e.g. #697e09", "id" => "woo_link_hover_color", "std" => "", "type" => "color");
     $options[] = array("name" => "Button Color", "desc" => "Pick a custom color for buttons or add a hex color code e.g. #697e09", "id" => "woo_button_color", "std" => "", "type" => "color");
     $options[] = array("name" => "Typography", "icon" => "typography", "id" => $shortname . "_typography_heading", "type" => "heading");
     $options[] = array("name" => "Enable Custom Typography", "desc" => "Enable the use of custom typography for your site. Custom styling will be output in your sites HEAD.", "id" => $shortname . "_typography", "std" => "false", "type" => "checkbox");
     $options[] = array("name" => "General Typography", "desc" => "Change the general font.", "id" => $shortname . "_font_body", "std" => array('size' => '12', 'unit' => 'px', 'face' => 'Arial', 'style' => '', 'color' => '#555555'), "type" => "typography");
     $options[] = array("name" => "Navigation", "desc" => "Change the navigation font.", "id" => $shortname . "_font_nav", "std" => array('size' => '14', 'unit' => 'px', 'face' => 'Arial', 'style' => '', 'color' => '#555555'), "type" => "typography");
     $options[] = array("name" => "Post Title", "desc" => "Change the post title.", "id" => $shortname . "_font_post_title", "std" => array('size' => '24', 'unit' => 'px', 'face' => 'Arial', 'style' => 'bold', 'color' => '#222222'), "type" => "typography");
     $options[] = array("name" => "Post Meta", "desc" => "Change the post meta.", "id" => $shortname . "_font_post_meta", "std" => array('size' => '11', 'unit' => 'px', 'face' => 'Arial', 'style' => '', 'color' => '#868686'), "type" => "typography");
     $options[] = array("name" => "Post Entry", "desc" => "Change the post entry.", "id" => $shortname . "_font_post_entry", "std" => array('size' => '14', 'unit' => 'px', 'face' => 'Arial', 'style' => '', 'color' => '#555555'), "type" => "typography");
     $options[] = array("name" => "Widget Titles", "desc" => "Change the widget titles.", "id" => $shortname . "_font_widget_titles", "std" => array('size' => '16', 'unit' => 'px', 'face' => 'Arial', 'style' => 'bold', 'color' => '#555555'), "type" => "typography");
     $options[] = array("name" => "Dynamic Images", "icon" => "image", "id" => $shortname . "_dynamic_images_heading", "type" => "heading");
     $options[] = array("name" => 'Dynamic Image Resizing', "desc" => "", "id" => $shortname . "_wpthumb_notice", "std" => 'There are two alternative methods of dynamically resizing the thumbnails in the theme, <strong>WP Post Thumbnail</strong> or <strong>TimThumb - Custom Settings panel</strong>. We recommend using WP Post Thumbnail option.', "type" => "info");
     $options[] = array("name" => "WP Post Thumbnail", "desc" => "Use WordPress post thumbnail to assign a post thumbnail. Will enable the <strong>Featured Image panel</strong> in your post sidebar where you can assign a post thumbnail.", "id" => $shortname . "_post_image_support", "std" => "true", "class" => "collapsed", "type" => "checkbox");
     $options[] = array("name" => "WP Post Thumbnail - Dynamic Image Resizing", "desc" => "The post thumbnail will be dynamically resized using native WP resize functionality. <em>(Requires PHP 5.2+)</em>", "id" => $shortname . "_pis_resize", "std" => "true", "class" => "hidden", "type" => "checkbox");
     $options[] = array("name" => "WP Post Thumbnail - Hard Crop", "desc" => "The post thumbnail will be cropped to match the target aspect ratio (only used if 'Dynamic Image Resizing' is enabled).", "id" => $shortname . "_pis_hard_crop", "std" => "true", "class" => "hidden last", "type" => "checkbox");
     $options[] = array("name" => "TimThumb - Custom Settings Panel", "desc" => "This will enable the <a href='http://code.google.com/p/timthumb/'>TimThumb</a> (thumb.php) script which dynamically resizes images added through the <strong>custom settings panel below the post</strong>. Make sure your themes <em>cache</em> folder is writable. <a href='http://www.woothemes.com/2008/10/troubleshooting-image-resizer-thumbphp/'>Need help?</a>", "id" => $shortname . "_resize", "std" => "true", "type" => "checkbox");
     $options[] = array("name" => "Automatic Image Thumbnail", "desc" => "If no thumbnail is specifified then the first uploaded image in the post is used.", "id" => $shortname . "_auto_img", "std" => "false", "type" => "checkbox");
     $options[] = array("name" => "Thumbnail Image Dimensions", "desc" => "Enter an integer value i.e. 250 for the desired size which will be used when dynamically creating the images.", "id" => $shortname . "_image_dimensions", "std" => "", "type" => array(array('id' => $shortname . '_thumb_w', 'type' => 'text', 'std' => 100, 'meta' => 'Width'), array('id' => $shortname . '_thumb_h', 'type' => 'text', 'std' => 100, 'meta' => 'Height')));
     $options[] = array("name" => "Thumbnail Image alignment", "desc" => "Select how to align your thumbnails with posts.", "id" => $shortname . "_thumb_align", "std" => "alignleft", "type" => "radio", "options" => $options_thumb_align);
     $options[] = array("name" => "Show thumbnail in Single Posts", "desc" => "Show the attached image in the single post page.", "id" => $shortname . "_thumb_single", "class" => "collapsed", "std" => "false", "type" => "checkbox");
     $options[] = array("name" => "Single Image Dimensions", "desc" => "Enter an integer value i.e. 250 for the image size. Max width is 576.", "id" => $shortname . "_image_dimensions", "std" => "", "class" => "hidden last", "type" => array(array('id' => $shortname . '_single_w', 'type' => 'text', 'std' => 200, 'meta' => 'Width'), array('id' => $shortname . '_single_h', 'type' => 'text', 'std' => 200, 'meta' => 'Height')));
     $options[] = array("name" => "Single Post Image alignment", "desc" => "Select how to align your thumbnail with single posts.", "id" => $shortname . "_thumb_single_align", "std" => "alignright", "type" => "radio", "class" => "hidden", "options" => $options_thumb_align);
     $options[] = array("name" => "Add thumbnail to RSS feed", "desc" => "Add the the image uploaded via your Custom Settings to your RSS feed", "id" => $shortname . "_rss_thumb", "std" => "false", "type" => "checkbox");
     //Footer
     $options[] = array("name" => "Footer Customization", "icon" => "footer", "id" => $shortname . "_footer_customization_heading", "type" => "heading");
     $options[] = array("name" => "Custom Affiliate Link", "desc" => "Add an affiliate link to the WooThemes logo in the footer of the theme.", "id" => $shortname . "_footer_aff_link", "std" => "", "type" => "text");
     $options[] = array("name" => "Enable Custom Footer (Left)", "desc" => "Activate to add the custom text below to the theme footer.", "id" => $shortname . "_footer_left", "class" => "collapsed", "std" => "false", "type" => "checkbox");
     $options[] = array("name" => "Custom Text (Left)", "desc" => "Custom HTML and Text that will appear in the footer of your theme.", "id" => $shortname . "_footer_left_text", "class" => "hidden last", "std" => "<p></p>", "type" => "textarea");
     $options[] = array("name" => "Enable Custom Footer (Right)", "desc" => "Activate to add the custom text below to the theme footer.", "id" => $shortname . "_footer_right", "class" => "collapsed", "std" => "false", "type" => "checkbox");
     $options[] = array("name" => "Custom Text (Right)", "desc" => "Custom HTML and Text that will appear in the footer of your theme.", "id" => $shortname . "_footer_right_text", "class" => "hidden last", "std" => "<p></p>", "type" => "textarea");
     //Advertising
     $options[] = array("name" => "Ads - Top Ad (468x60px)", "icon" => "ads", "id" => $shortname . "_ads_top_ad_heading", "type" => "heading");
     $options[] = array("name" => "Enable Ad", "desc" => "Enable the ad space", "id" => $shortname . "_ad_top", "std" => "false", "type" => "checkbox");
     $options[] = array("name" => "Adsense code", "desc" => "Enter your adsense code (or other ad network code) here.", "id" => $shortname . "_ad_top_adsense", "std" => "", "type" => "textarea");
     $options[] = array("name" => "Image Location", "desc" => "Enter the URL to the banner ad image location.", "id" => $shortname . "_ad_top_image", "std" => "http://www.woothemes.com/ads/468x60b.jpg", "type" => "upload");
     $options[] = array("name" => "Destination URL", "desc" => "Enter the URL where this banner ad points to.", "id" => $shortname . "_ad_top_url", "std" => "http://www.woothemes.com", "type" => "text");
     // Dynamic Search
     $options[] = array("name" => "Search Fields", "icon" => "searchoption", "id" => $shortname . "_search_fields_heading", "type" => "heading");
     $number_of_search_fields = 3;
     update_option('woo_number_of_search_fields', $number_of_search_fields);
     //Unset array items that we dont want
     if ($woo_wp_custom_taxonomies_formatted['nav_menu'] != '') {
         unset($woo_wp_custom_taxonomies_formatted['nav_menu']);
     }
     if ($woo_wp_custom_taxonomies_formatted['link_category'] != '') {
         unset($woo_wp_custom_taxonomies_formatted['link_category']);
     }
     //Unset array items that we dont want
     if ($woo_wp_custom_post_types_formatted['nav_menu_item'] != '') {
         unset($woo_wp_custom_post_types_formatted['nav_menu_item']);
     }
     if ($woo_wp_custom_post_types_formatted['attachment'] != '') {
         unset($woo_wp_custom_post_types_formatted['attachment']);
     }
     if ($woo_wp_custom_post_types_formatted['revision'] != '') {
         unset($woo_wp_custom_post_types_formatted['revision']);
     }
     if ($woo_wp_custom_post_types_formatted['wooframework'] != '') {
         unset($woo_wp_custom_post_types_formatted['wooframework']);
     }
     // SEARCH FIELDS LOOP
     for ($counter = 1; $counter <= $number_of_search_fields; $counter += 1) {
         $options[] = array("name" => "<strong>Field " . $counter . " Search Settings</strong>", "type" => "info", "std" => "<small>The below settings only apply to Field " . $counter . " of the search. You can switch off this field by setting the input type to 'None'. </small>");
         $options[] = array("name" => "Input Type", "desc" => "This is the type of input field that will be shown to the user.", "id" => $shortname . "_search_input_content_type_" . $counter, "std" => "none", "options" => array('none' => 'None', 'text' => 'Text box', 'autocomplete' => 'Autocomplete Text box', 'select2' => 'Drop down box'), "type" => "select2");
         $options[] = array("name" => "Content Label", "desc" => "Enter the label description for the content field on the frontend - if this is blank the name of the Content Type will be displayed.", "id" => $shortname . "_search_content_type_label_" . $counter, "std" => "", "type" => "text");
         $options[] = array("name" => "Content Type", "desc" => "Choose the type of content for this search field.", "id" => $shortname . "_search_content_type_" . $counter, "std" => "ctx", "type" => "select2", "options" => array('ctx' => 'Taxonomy', 'cmb' => 'Custom Field'));
         $options[] = array("name" => "Taxonomy", "desc" => "Select a taxonomy for the search field", "id" => $shortname . "_search_content_type_ctx_" . $counter, "std" => "none", "type" => "select2", "options" => $woo_wp_custom_taxonomies_formatted);
         $options[] = array("name" => "Custom Field", "desc" => "Select a custom field for the search field", "id" => $shortname . "_search_content_type_cmb_" . $counter, "std" => "none", "type" => "select2", "options" => $woo_wp_custom_fields_formatted);
         $options[] = array("name" => "Post Type", "desc" => "Select a post type for the search field", "id" => $shortname . "_search_content_type_cpt_" . $counter, "std" => "none", "type" => "select2", "options" => $woo_wp_custom_post_types_formatted);
         $options[] = array("name" => "Search by Features Matching Method", "desc" => "Choose the matching method for Search Results. <br /><strong>Exact Match</strong> means only results with the same number of this item searched for will be returned while <strong>Minimum Value</strong> means that all results with at least the amount searched for will be returned. <strong>NOTE: Only use minimum value on numeric fields otherwise the desired result will not be achieved.</strong>", "id" => $shortname . "_search_content_type_matching_method_" . $counter, "std" => "exact", "type" => "radio", "class" => "hidden", "options" => array("exact" => "Exact Match", "minimum" => "Minimum Value"));
         //Boolean Logic
         $options[] = array("name" => "Chaining Logic", "desc" => "This alters the search logic. AND means results must have this field match as well, OR means results will contain matches for both fields.", "id" => $shortname . "_search_content_type_boolean_logic_" . $counter, "std" => "and", "type" => "select2", "class" => "hidden", "options" => array('and' => 'AND', 'or' => 'OR'));
     }
     $options[] = array("name" => "Search Options", "icon" => "searchoption", "id" => $shortname . "_search_options_heading", "type" => "heading");
     $options[] = array("name" => "Homepage Display Search Panel", "desc" => "Sets the Search Panel state to open by default on the homepage. This will override the below global option.", "id" => $shortname . "_search_panel_state", "std" => "true", "type" => "checkbox");
     $options[] = array("name" => "Global Display Search Panel", "desc" => "Sets the Search Panel state to open by default across the site.", "id" => $shortname . "_search_panel_state_global", "std" => "false", "type" => "checkbox");
     //set post types array to just posts and listings
     unset($woo_wp_custom_post_types_formatted['none']);
     unset($woo_wp_custom_post_types_formatted['page']);
     $options[] = array("name" => "Search Post Types", "desc" => "Select which post types you would like the search to query.", "id" => $shortname . "_search_post_types", "std" => 'listing', "type" => "multicheck", "options" => $woo_wp_custom_post_types_formatted);
     $options[] = array("name" => "Search Results", "desc" => "Select the number of entries that should appear on the search results page.", "id" => $shortname . "_listings_search_results", "std" => "3", "type" => "select", "options" => $other_entries);
     $options[] = array("name" => "Search by Features Matching Method", "desc" => "Choose the matching method for Custom Field Search Results. <br /><strong>Exact Match</strong> means only results with the same number of this item searched for will be returned while <strong>Minimum Value</strong> means that all results with at least the amount searched for will be returned. <strong>NOTE: Only use minimum value will only be applied on numeric fields otherwise the desired result will not be achieved.</strong>", "id" => $shortname . "_search_content_type_matching_method", "std" => "exact", "type" => "radio", "class" => "", "options" => array("exact" => "Exact Match", "minimum" => "Minimum Value"));
     // General Labels
     $options[] = array("name" => "Labels : General", "icon" => "listing\t", "id" => $shortname . "_labels_general_heading", "type" => "heading");
     $options[] = array("name" => "Listings Prefix Symbol", "desc" => "Specify the prefix that will be attached to a listing to give it a unique number that can be used in the search.", "id" => $shortname . "_listings_prefix", "std" => "LIST", "type" => "text");
     $options[] = array("name" => "Currency Symbol", "desc" => "Specify the currency that your listings price will be shown in.", "id" => $shortname . "_listings_currency", "std" => "\$", "type" => "text");
     $options[] = array("name" => "Search Panel Title", "desc" => "Include a short title for your search panel on the home page, e.g. Advanced Search Module.", "id" => $shortname . "_search_panel_header", "std" => "Advanced Search Module", "type" => "text");
     $options[] = array("name" => "Search Listings Keyword Input Text", "desc" => "Specify the default text in the search keyword input box.", "id" => $shortname . "_search_panel_keyword_text", "std" => "Enter search keywords", "type" => "text");
     $options[] = array("name" => "Search Listings Button Text", "desc" => "Specify the default text for the search listings button.", "id" => $shortname . "_search_panel_listings_button_text", "std" => "Search Site", "type" => "text");
     $options[] = array("name" => "Search WebRef Input Text", "desc" => "Specify the default text in the search keyword input box.", "id" => $shortname . "_search_panel_webref_text", "std" => "Listings ID", "type" => "text");
     $options[] = array("name" => "Search WebRef Button Text", "desc" => "Specify the default text for the search by webref button.", "id" => $shortname . "_search_panel_webref_button_text", "std" => "Go To", "type" => "text");
     $options[] = array("name" => "Search Results Title", "desc" => "Specify the default text for the search results title.", "id" => $shortname . "_search_results_header", "std" => "Search results:", "type" => "text");
     $options[] = array("name" => "Archive Text : Listings", "desc" => "Specify the default text for the listings archive page headers.", "id" => $shortname . "_archive_listings_header", "std" => "Listings Archive", "type" => "text");
     $options[] = array("name" => "Archive Text : General", "desc" => "Specify the default text for the general archive page headers.", "id" => $shortname . "_archive_general_header", "std" => "Archive", "type" => "text");
     $options[] = array("name" => "'Latest Listings' header text", "desc" => "Specify the default text for the header area on the 'latest listings' page.", "id" => $shortname . "_listings_more_header", "std" => "Latest listings", "type" => "text");
     $options[] = array("name" => "'View more latest listings' link text", "desc" => "Specify the default text for the 'view more latest listings' link in the footer.", "id" => $shortname . "_listings_viewmore_label", "std" => "View more latest listings", "type" => "text");
     // Featured Panel
     $options[] = array("name" => "Featured Panel", "icon" => "slider", "id" => $shortname . "_featured_panel_heading", "type" => "heading");
     $options[] = array("name" => "Enable Featured Panel", "desc" => "Show the featured panel on the front page.", "id" => $shortname . "_featured", "std" => "false", "type" => "checkbox");
     $options[] = array("name" => "Featured Panel Title", "desc" => "Include a short title for your featured panel on the home page, e.g. Featured Listings.", "id" => $shortname . "_featured_header", "std" => "Featured Listings", "type" => "text");
     $options[] = array("name" => "Featured Tag", "desc" => "Add comma separated list for the tags that you would like to have displayed in the featured section on your homepage. For example, if you add 'tag1, tag3' here, then all properties tagged with either 'tag1' or 'tag3' will be shown in the featured area.", "id" => $shortname . "_featured_tags", "std" => "", "type" => "text");
     $options[] = array("name" => "Featured Entries", "desc" => "Select the number of listing entries that should appear in the Featured panel.", "id" => $shortname . "_featured_entries", "std" => "3", "type" => "select", "options" => $other_entries);
     $options[] = array("name" => "Slider Image Position", "desc" => "Select the alignment for the featured slider image", "id" => $shortname . "_slider_image", "std" => "Left", "type" => "select", "options" => $slider_image);
     $options[] = array("name" => "Custom Field for Image Caption", "desc" => "Select a custom field for the image caption", "id" => $shortname . "_slider_image_caption", "std" => "price", "type" => "select2", "options" => $woo_wp_custom_fields_formatted);
     $options[] = array("name" => "Effect", "desc" => "Select the animation effect. ", "id" => $shortname . "_slider_effect", "type" => "select2", "std" => "fade", "options" => array("slide" => "Slide", "fade" => "Fade"));
     $options[] = array("name" => "Hover Pause", "desc" => "Hovering over slideshow will pause it", "id" => $shortname . "_slider_hover", "std" => "false", "type" => "checkbox");
     $options[] = array("name" => "Fade Speed", "desc" => "The time in <b>seconds</b> the fade between frames will take.", "id" => $shortname . "_fade_speed", "std" => "0.6", "type" => "select", "options" => array('0.0', '0.1', '0.2', '0.3', '0.4', '0.5', '0.6', '0.7', '0.8', '0.9', '1.0', '1.1', '1.2', '1.3', '1.4', '1.5', '1.6', '1.7', '1.8', '1.9', '2.0'));
     $options[] = array("name" => "Auto Start", "desc" => "Set the slider to start sliding automatically. Adjust the speed of sliding underneath.", "id" => $shortname . "_slider_auto", "std" => "false", "type" => "checkbox");
     $options[] = array("name" => "Animation Speed", "desc" => "The time in <b>seconds</b> the animation between frames will take e.g. 0.6", "id" => $shortname . "_slider_speed", "std" => "0.6", "type" => "select", "options" => array('0.0', '0.1', '0.2', '0.3', '0.4', '0.5', '0.6', '0.7', '0.8', '0.9', '1.0', '1.1', '1.2', '1.3', '1.4', '1.5', '1.6', '1.7', '1.8', '1.9', '2.0'));
     $options[] = array("name" => "Auto Slide Interval", "desc" => "The time in <b>seconds</b> each slide pauses for, before sliding to the next. Only when using Auto Start option above.", "id" => $shortname . "_slider_interval", "std" => "6", "type" => "select", "options" => array('1', '2', '3', '4', '5', '6', '7', '8', '9', '10'));
     // Listing Categories Panel
     $options[] = array("name" => "Listing Categories Panel", "icon" => "listing", "id" => $shortname . "_listings_categories_panel_heading", "type" => "heading");
     //set post types array to just posts and listings
     $temp_cpt_list = $woo_wp_custom_post_types_formatted;
     unset($temp_cpt_list['none']);
     unset($temp_cpt_list['page']);
     if (isset($temp_cpt_list['nav_menu_item']) && $temp_cpt_list['nav_menu_item'] != '') {
         unset($temp_cpt_list['nav_menu_item']);
     }
     if (isset($temp_cpt_list['attachment']) && $temp_cpt_list['attachment'] != '') {
         unset($temp_cpt_list['attachment']);
     }
     if (isset($temp_cpt_list['revision']) && $temp_cpt_list['revision'] != '') {
         unset($temp_cpt_list['revision']);
     }
     if (isset($temp_cpt_list['wooframework']) && $temp_cpt_list['wooframework'] != '') {
         unset($temp_cpt_list['wooframework']);
     }
     $options[] = array("name" => "Display List for these Post Types", "desc" => "Select which post types you would like to generate a list of taxonomies for.", "id" => $shortname . "_categories_panel_post_types", "std" => 'listing', "type" => "multicheck", "options" => $temp_cpt_list);
     //set taxonomies array default
     $temp_ctx_list = $woo_wp_custom_taxonomies_formatted;
     unset($temp_ctx_list['none']);
     $options[] = array("name" => "Taxonomies to Output", "desc" => "Select which taxonomy terms you would like to display in the Listings Category Panel for each of the above Post Types.", "id" => $shortname . "_categories_panel_taxonomies", "std" => 'location', "type" => "multicheck", "options" => $temp_ctx_list);
     $options[] = array("name" => "Number of Taxonomy Entries", "desc" => "Select the number of taxonomy entries that should appear in each Listing Categories panel.", "id" => $shortname . "_categories_panel_entries", "std" => "6", "type" => "select", "options" => $other_entries);
     // More Listings Panel
     $options[] = array("name" => "More Listings Panel", "icon" => "listing", "id" => $shortname . "_more_listings_panel_heading", "type" => "heading");
     $options[] = array("name" => "Enable More Listings Panel", "desc" => "Enable the More Listings panel below the Listing Categories Panel.", "id" => $shortname . "_more_listings_area", "std" => "false", "type" => "checkbox");
     $options[] = array("name" => "Display List for these Post Types", "desc" => "Select which post types you would like to display More Listings for.", "id" => $shortname . "_more_listings_area_post_types", "std" => 'listing', "type" => "multicheck", "options" => $temp_cpt_list);
     $options[] = array("name" => "Number of Entries", "desc" => "Select the number of entries that should appear in the More Listings panel.", "id" => $shortname . "_more_listings_area_entries", "std" => "3", "type" => "select", "options" => $other_entries);
     $options[] = array("name" => "Popular Keywords", "icon" => "header", "id" => $shortname . "_popular_keywords_heading", "type" => "heading");
     $options[] = array("name" => "Enable Popular Keywords", "desc" => "Enable the popular keywords section in the search module.", "id" => $shortname . "_keywords", "std" => "false", "type" => "checkbox");
     $options[] = array("name" => "Popular Keywords Panel Title", "desc" => "Include a short title for your popular keywords panel on the home page, e.g. Popular Keywords.", "id" => $shortname . "_popular_keywords_header", "std" => "Popular Keywords", "type" => "text");
     //set taxonomies array default
     unset($woo_wp_custom_taxonomies_formatted['none']);
     $options[] = array("name" => "Popular Keywords Taxonomies", "desc" => "Select which taxonomy terms you would like to display in the popular keywords panel.", "id" => $shortname . "_search_post_types", "std" => 'location', "type" => "multicheck", "options" => $woo_wp_custom_taxonomies_formatted);
     $options[] = array("name" => "Number of Popular Keywords per Taxonomy", "desc" => "The number of popular keywords to include from each taxonomy.", "id" => $shortname . "_popular_keywords_limit", "std" => "20", "type" => "text");
     // Single Listing Setting
     $options[] = array("name" => "Single Listing Details", "icon" => "main", "id" => $shortname . "_single_listings_details_heading", "type" => "heading");
     $options[] = array("name" => "Features Taxonomy", "desc" => "Select a taxonomy for the listing features area", "id" => $shortname . "_single_listing_feature_taxonomy", "std" => "listingfeatures", "type" => "select2", "options" => $woo_wp_custom_taxonomies_formatted);
     $options[] = array("name" => "Similar Listings Taxonomy", "desc" => "Select a taxonomy to match Similar Listings by", "id" => $shortname . "_single_listing_related_taxonomy", "std" => "location", "type" => "select2", "options" => $woo_wp_custom_taxonomies_formatted);
     $options[] = array("name" => "Custom Field for Image Caption", "desc" => "Select a custom field for the image caption", "id" => $shortname . "_single_listing_image_caption", "std" => "price", "type" => "select2", "options" => $woo_wp_custom_fields_formatted);
     $options[] = array("name" => "Starting at Text", "desc" => "Specify the default text for the Starting at area.", "id" => $shortname . "_single_listing_starting_at_text", "std" => "Starting at ", "type" => "text");
     $options[] = array("name" => "Image Gallery Title Text", "desc" => "Specify the default text for the Image Gallery title.", "id" => $shortname . "_single_listing_image_gallery_title", "std" => "Image Gallery", "type" => "text");
     $options[] = array("name" => "Google Map Title Text", "desc" => "Specify the default text for the Google Map title.", "id" => $shortname . "_single_listing_google_map_title", "std" => "Location", "type" => "text");
     $options[] = array("name" => "Similar Listings Title Text", "desc" => "Specify the default text for the Similar Listings title.", "id" => $shortname . "_single_listing_similar_listings_title", "std" => "Similar Listings", "type" => "text");
     // Upload Listing Page Template
     $options[] = array("name" => "Upload Listing", "icon" => "upload", "id" => $shortname . "_upload_listing_heading", "type" => "heading");
     $options[] = array("name" => "Only Register Users may post a Listing", "desc" => "This forces users to register before being able to add a listing.", "id" => $shortname . "_upload_user_logged_in", "std" => "false", "type" => "checkbox");
     $options[] = array("name" => "Upload Post Types", "desc" => "Select which post types you would users to be able to upload.", "id" => $shortname . "_upload_post_types", "std" => 'listing', "type" => "multicheck", "options" => $woo_wp_custom_post_types_formatted);
     // Google Maps Settings
     $options[] = array("name" => "Maps", "icon" => "maps", "id" => $shortname . "_maps_heading", "type" => "heading");
     $options[] = array("name" => "Google Maps API Key", "desc" => "Enter your Google Maps API key before using any of Postcard's mapping functionality. <a href='http://code.google.com/apis/maps/signup.html'>Signup for an API key here</a>.", "id" => $shortname . "_maps_apikey", "std" => "", "class" => "hidden", "type" => "text");
     $options[] = array("name" => "Disable Mousescroll", "desc" => "Turn off the mouse scroll action for all the Google Maps on the site. This could improve usability on your site.", "id" => $shortname . "_maps_scroll", "std" => "", "type" => "checkbox");
     $options[] = array("name" => "Single Page Map Height", "desc" => "Height in pixels for the maps displayed on Single.php pages.", "id" => $shortname . "_maps_single_height", "std" => "250", "type" => "text");
     $options[] = array("name" => "Enable Latitude & Longitude Coordinates:", "desc" => "Enable or disable coordinates in the head of single posts pages.", "id" => $shortname . "_coords", "std" => "true", "type" => "checkbox");
     $options[] = array("name" => "Default Map Zoom Level", "desc" => "Set this to adjust the default in the post & page edit backend.", "id" => $shortname . "_maps_default_mapzoom", "std" => "10", "type" => "select2", "options" => $zoom);
     $options[] = array("name" => "Default Map Type", "desc" => "Set this to the default rendered in the post backend.", "id" => $shortname . "_maps_default_maptype", "std" => "Normal", "type" => "select2", "options" => array('G_NORMAL_MAP' => 'Normal', 'G_SATELLITE_MAP' => 'Satellite', 'G_HYBRID_MAP' => 'Hybrid', 'G_PHYSICAL_MAP' => 'Terrain'));
     $options[] = array("name" => "Archive Maps", "icon" => "maps", "id" => $shortname . "_archive_maps_heading", "type" => "heading");
     $options[] = array("name" => "Enable Archive Maps", "desc" => "Enable a map with markers relative the listings on the current archive page.", "id" => $shortname . "_show_archive_map", "std" => "false", "type" => "checkbox");
     $options[] = array("name" => "Overview map type", "desc" => "Select the type of map you would like to produce on archive pages.", "id" => $shortname . "_archive_type", "std" => "G_NORMAL_MAP", "options" => array('G_NORMAL_MAP' => 'Normal', 'G_SATELLITE_MAP' => 'Satellite', 'G_HYBRID_MAP' => 'Hybrid', 'G_PHYSICAL_MAP' => 'Physical'), "type" => "select2");
     $options[] = array("name" => "Overview map zoom", "desc" => "Select the type of map you would like to produce on archive pages.", "id" => $shortname . "_archive_zoom", "std" => "10", "options" => $zoom, "type" => "select");
     $options[] = array("name" => "Disable Mousescroll", "desc" => "Turn off the mouse scroll action for all the Google Maps on the archive pages. This could improve usability on your site.", "id" => $shortname . "_maps_archive_scroll", "std" => "", "type" => "checkbox");
     $options[] = array("name" => "Object Dimensions", "desc" => "Enter the size of the map or image featured on the archive featured area.", "id" => $shortname . "_image_dimensions", "std" => "", "type" => array(array('id' => $shortname . '_archive_featured_h', 'type' => 'text', 'std' => 250, 'meta' => 'Height')));
     $options[] = array("name" => "Number of Pins (Posts)", "desc" => "Adjust the amount of pins (posts) you want to show on the archive overview map. <strong>-1</strong> is show all.", "id" => $shortname . "_cat_show_pins", "std" => "20", "type" => "text");
     $options = category_nav($options, $colors);
     // Filter
     $options = apply_filters('woothemes_theme_options', $options);
     if (get_option('woo_template') != $options) {
         update_option('woo_template', $options);
     }
     if (get_option('woo_themename') != $themename) {
         update_option('woo_themename', $themename);
     }
     if (get_option('woo_shortname') != $shortname) {
         update_option('woo_shortname', $shortname);
     }
     if (get_option('woo_manual') != $manualurl) {
         update_option('woo_manual', $manualurl);
     }
     // Woo Metabox Options
     // Start name with underscore to hide custom key from the user
     $woo_metaboxes = array();
     if (get_post_type() == 'post') {
         $woo_metaboxes[] = array("name" => "image", "label" => "Image", "type" => "upload", "desc" => "Upload an image or enter an URL.");
         if (get_option('woo_resize') == "true") {
             $woo_metaboxes[] = array("name" => "_image_alignment", "std" => "Center", "label" => "Image Crop Alignment", "type" => "select2", "desc" => "Select crop alignment for resized image", "options" => array("c" => "Center", "t" => "Top", "b" => "Bottom", "l" => "Left", "r" => "Right"));
         }
     }
     // End post
     // Old post custom fields go here - controlled by content builder now
     //Only show SEO on these registered post types
     //Only show SEO on these registered post types
 }
 function woo_options()
 {
     // THEME VARIABLES
     $themename = "Swatch";
     $themeslug = "swatch";
     // STANDARD VARIABLES. DO NOT TOUCH!
     $shortname = "woo";
     $manualurl = 'http://www.woothemes.com/support/theme-documentation/' . $themeslug . '/';
     //Access the NXTClass Categories via an Array
     $woo_categories = array();
     $woo_categories_obj = get_categories('hide_empty=0');
     foreach ($woo_categories_obj as $woo_cat) {
         $woo_categories[$woo_cat->cat_ID] = $woo_cat->cat_name;
     }
     $categories_tmp = array_unshift($woo_categories, "Select a category:");
     //Access the NXTClass Pages via an Array
     $woo_pages = array();
     $woo_pages_obj = get_pages('sort_column=post_parent,menu_order');
     foreach ($woo_pages_obj as $woo_page) {
         $woo_pages[$woo_page->ID] = $woo_page->post_name;
     }
     $woo_pages_tmp = array_unshift($woo_pages, "Select a page:");
     //Stylesheets Reader
     $alt_stylesheet_path = get_template_directory() . '/styles/';
     $alt_stylesheets = array();
     if (is_dir($alt_stylesheet_path)) {
         if ($alt_stylesheet_dir = opendir($alt_stylesheet_path)) {
             while (($alt_stylesheet_file = readdir($alt_stylesheet_dir)) !== false) {
                 if (stristr($alt_stylesheet_file, ".css") !== false) {
                     $alt_stylesheets[] = $alt_stylesheet_file;
                 }
             }
         }
     }
     //More Options
     $other_entries = array("Select a number:", "1", "2", "3", "4", "5", "6", "7", "8", "9", "10", "11", "12", "13", "14", "15", "16", "17", "18", "19");
     //URL Shorteners
     if (_iscurlinstalled()) {
         $options_select = array("Off", "TinyURL", "Bit.ly");
         $short_url_msg = 'Select the URL shortening service you would like to use.';
     } else {
         $options_select = array("Off");
         $short_url_msg = '<strong>cURL was not detected on your server, and is required in order to use the URL shortening services.</strong>';
     }
     // Setup an array of pages for a dropdown.
     $args = array('echo' => 0);
     $pages_dropdown = nxt_dropdown_pages($args);
     $pages = array();
     // Quick string hack to make sure we get the pages with the indents.
     $pages_dropdown = str_replace('<select name="page_id" id="page_id">', '', $pages_dropdown);
     $pages_dropdown = str_replace('</select>', '', $pages_dropdown);
     $pages_split = explode('</option>', $pages_dropdown);
     $pages[] = __('Select a Page:', 'woothemes');
     foreach ($pages_split as $k => $v) {
         $id = '';
         // Get the ID value.
         preg_match('/value="(.*?)"/i', $v, $matches);
         if (isset($matches[1])) {
             $id = $matches[1];
             $pages[$id] = trim(strip_tags($v));
         }
     }
     // End FOREACH Loop
     $woo_pages = $pages;
     // THIS IS THE DIFFERENT FIELDS
     $options = array();
     /* General */
     $options[] = array("name" => __('General Settings', 'woothemes'), "type" => "heading", "icon" => "general");
     $options[] = array("name" => __('Theme Stylesheet', 'woothemes'), "desc" => __('Select your themes alternative color scheme.', 'woothemes'), "id" => $shortname . "_alt_stylesheet", "std" => "default.css", "type" => "select", "options" => $alt_stylesheets);
     $options[] = array("name" => __('Custom Logo', 'woothemes'), "desc" => __('Upload a logo for your theme, or specify an image URL directly.', 'woothemes'), "id" => $shortname . "_logo", "std" => "", "type" => "upload");
     $options[] = array("name" => __('Text Title', 'woothemes'), "desc" => sprintf(__('Enable text-based Site Title and Tagline. Setup title & tagline in %1$s.', 'woothemes'), '<a href="' . home_url() . '/nxt-admin/options-general.php">' . __('General Settings', 'woothemes') . '</a>'), "id" => $shortname . "_texttitle", "std" => "false", "class" => "collapsed", "type" => "checkbox");
     $options[] = array("name" => __('Site Title', 'woothemes'), "desc" => __('Change the site title typography.', 'woothemes'), "id" => $shortname . "_font_site_title", "std" => array('size' => '70', 'unit' => 'px', 'face' => 'StMarie-Thin', 'style' => 'normal', 'color' => '#3E3E3E'), "class" => "hidden", "type" => "typography");
     $options[] = array("name" => __('Site Description', 'woothemes'), "desc" => __('Enable the site description/tagline under site title.', 'woothemes'), "id" => $shortname . "_tagline", "class" => "hidden", "std" => "false", "type" => "checkbox");
     $options[] = array("name" => __('Site Description', 'woothemes'), "desc" => __('Change the site description typography.', 'woothemes'), "id" => $shortname . "_font_tagline", "std" => array('size' => '26', 'unit' => 'px', 'face' => 'BergamoStd-Italic', 'style' => 'italic', 'color' => '#3E3E3E'), "class" => "hidden last", "type" => "typography");
     $options[] = array("name" => __('Custom Favicon', 'woothemes'), "desc" => __('Upload a 16px x 16px <a href="http://www.faviconr.com/">ico image</a> that will represent your website\'s favicon.', 'woothemes'), "id" => $shortname . "_custom_favicon", "std" => "", "type" => "upload");
     $options[] = array("name" => __('Tracking Code', 'woothemes'), "desc" => __('Paste your Google Analytics (or other) tracking code here. This will be added into the footer template of your theme.', 'woothemes'), "id" => $shortname . "_google_analytics", "std" => "", "type" => "textarea");
     $options[] = array("name" => __('RSS URL', 'woothemes'), "desc" => __('Enter your preferred RSS URL. (Feedburner or other)', 'woothemes'), "id" => $shortname . "_feed_url", "std" => "", "type" => "text");
     $options[] = array("name" => __('E-Mail Subscription URL', 'woothemes'), "desc" => __('Enter your preferred E-mail subscription URL. (Feedburner or other)', 'woothemes'), "id" => $shortname . "_subscribe_email", "std" => "", "type" => "text");
     $options[] = array("name" => __('Contact Form E-Mail', 'woothemes'), "desc" => __('Enter your E-mail address to use on the Contact Form Page Template. Add the contact form by adding a new page and selecting "Contact Form" as page template.', 'woothemes'), "id" => $shortname . "_contactform_email", "std" => "", "type" => "text");
     $options[] = array("name" => __('Custom CSS', 'woothemes'), "desc" => __('Quickly add some CSS to your theme by adding it to this block.', 'woothemes'), "id" => $shortname . "_custom_css", "std" => "", "type" => "textarea");
     $options[] = array("name" => __('Post/Page Comments', 'woothemes'), "desc" => __('Select if you want to enable/disable comments on posts and/or pages.', 'woothemes'), "id" => $shortname . "_comments", "std" => "both", "type" => "select2", "options" => array("post" => __('Posts Only', 'woothemes'), "page" => __('Pages Only', 'woothemes'), "both" => __('Pages / Posts', 'woothemes'), "none" => __('None', 'woothemes')));
     $options[] = array("name" => __('Post Content', 'woothemes'), "desc" => __('Select if you want to show the full content or the excerpt on posts.', 'woothemes'), "id" => $shortname . "_post_content", "type" => "select2", "options" => array("excerpt" => __('The Excerpt', 'woothemes'), "content" => __('Full Content', 'woothemes')));
     $options[] = array("name" => __('Post Author Box', 'woothemes'), "desc" => sprintf(__('This will enable the post author box on the single posts page. Edit description in %1$s.', 'woothemes'), '<a href="' . home_url() . '/nxt-admin/profile.php">' . __('Profile', 'woothemes') . '</a>'), "id" => $shortname . "_post_author", "std" => "true", "type" => "checkbox");
     $options[] = array("name" => __('Display Breadcrumbs', 'woothemes'), "desc" => __('Display dynamic breadcrumbs on each page of your website.', 'woothemes'), "id" => $shortname . "_breadcrumbs_show", "std" => "false", "type" => "checkbox");
     $options[] = array("name" => __('Pagination Style', 'woothemes'), "desc" => __('Select the style of pagination you would like to use on the blog.', 'woothemes'), "id" => $shortname . "_pagination_type", "type" => "select2", "options" => array("paginated_links" => __('Numbers', 'woothemes'), "simple" => __('Next/Previous', 'woothemes')));
     /* Styling */
     $options[] = array("name" => __('Styling Options', 'woothemes'), "type" => "heading", "icon" => "styling");
     $options[] = array("name" => __('Body Background Color', 'woothemes'), "desc" => __('Pick a custom color for background color of the theme e.g. #697e09', 'woothemes'), "id" => "woo_body_color", "std" => "", "type" => "color");
     $options[] = array("name" => __('Body background image', 'woothemes'), "desc" => __('Upload an image for the theme\'s background', 'woothemes'), "id" => $shortname . "_body_img", "std" => "", "type" => "upload");
     $options[] = array("name" => __('Background image repeat', 'woothemes'), "desc" => __('Select how you would like to repeat the background-image', 'woothemes'), "id" => $shortname . "_body_repeat", "std" => "no-repeat", "type" => "select", "options" => array("no-repeat", "repeat-x", "repeat-y", "repeat"));
     $options[] = array("name" => __('Background image position', 'woothemes'), "desc" => __('Select how you would like to position the background', 'woothemes'), "id" => $shortname . "_body_pos", "std" => "top", "type" => "select", "options" => array("top left", "top center", "top right", "center left", "center center", "center right", "bottom left", "bottom center", "bottom right"));
     $options[] = array("name" => __('Link Color', 'woothemes'), "desc" => __('Pick a custom color for links or add a hex color code e.g. #697e09', 'woothemes'), "id" => "woo_link_color", "std" => "", "type" => "color");
     $options[] = array("name" => __('Link Hover Color', 'woothemes'), "desc" => __('Pick a custom color for links hover or add a hex color code e.g. #697e09', 'woothemes'), "id" => "woo_link_hover_color", "std" => "", "type" => "color");
     $options[] = array("name" => __('Button Color', 'woothemes'), "desc" => __('Pick a custom color for buttons or add a hex color code e.g. #697e09', 'woothemes'), "id" => "woo_button_color", "std" => "", "type" => "color");
     /* Typography */
     $options[] = array("name" => __('Typography', 'woothemes'), "type" => "heading", "icon" => "typography");
     $options[] = array("name" => __('Enable Custom Typography', 'woothemes'), "desc" => __('Enable the use of custom typography for your site. Custom styling will be output in your sites HEAD.', 'woothemes'), "id" => $shortname . "_typography", "std" => "false", "type" => "checkbox");
     $options[] = array("name" => __('General Typography', 'woothemes'), "desc" => __('Change the general font.', 'woothemes'), "id" => $shortname . "_font_body", "std" => array('size' => '14', 'unit' => 'px', 'face' => 'Arial', 'style' => '', 'color' => '#444444'), "type" => "typography");
     $options[] = array("name" => __('Navigation', 'woothemes'), "desc" => __('Change the navigation font.', 'woothemes'), "id" => $shortname . "_font_nav", "std" => array('size' => '13', 'unit' => 'px', 'face' => 'Arial', 'style' => '', 'color' => '#FFFFFF'), "type" => "typography");
     $options[] = array("name" => __('Post Title', 'woothemes'), "desc" => __('Change the post title.', 'woothemes'), "id" => $shortname . "_font_post_title", "std" => array('size' => '30', 'unit' => 'px', 'face' => 'Arial', 'style' => 'bold', 'color' => '#444444'), "type" => "typography");
     $options[] = array("name" => __('Post Meta', 'woothemes'), "desc" => __('Change the post meta.', 'woothemes'), "id" => $shortname . "_font_post_meta", "std" => array('size' => '12', 'unit' => 'px', 'face' => 'Lucida Grande', 'style' => '', 'color' => '#444444'), "type" => "typography");
     $options[] = array("name" => __('Post Entry', 'woothemes'), "desc" => __('Change the post entry.', 'woothemes'), "id" => $shortname . "_font_post_entry", "std" => array('size' => '14', 'unit' => 'px', 'face' => 'Arial', 'style' => '', 'color' => '#444444'), "type" => "typography");
     $options[] = array("name" => __('Sidebar Widget Titles', 'woothemes'), "desc" => __('Change the sidebar widget titles.', 'woothemes'), "id" => $shortname . "_font_widget_titles", "std" => array('size' => '16', 'unit' => 'px', 'face' => 'Georgia', 'style' => 'bold', 'color' => '#444444'), "type" => "typography");
     $options[] = array("name" => __('Footer Widget Titles', 'woothemes'), "desc" => __('Change the footer widget titles.', 'woothemes'), "id" => $shortname . "_font_footer_widget_titles", "std" => array('size' => '10', 'unit' => 'px', 'face' => 'Arial', 'style' => 'normal', 'color' => '#AAA8A8'), "type" => "typography");
     /* Layout */
     $options[] = array("name" => __('Layout Options', 'woothemes'), "type" => "heading", "icon" => "layout");
     $url = get_template_directory_uri() . '/functions/images/';
     $options[] = array("name" => __('Main Layout', 'woothemes'), "desc" => __('Select which layout you want for your site.', 'woothemes'), "id" => $shortname . "_site_layout", "std" => "layout-left-content", "type" => "images", "options" => array('layout-left-content' => $url . '2cl.png', 'layout-right-content' => $url . '2cr.png'));
     $options[] = array("name" => __('Category Exclude - Homepage', 'woothemes'), "desc" => __('Specify a comma seperated list of category IDs or slugs that you\'d like to exclude from your homepage (eg: uncategorized).', 'woothemes'), "id" => $shortname . "_exclude_cats_home", "std" => "", "type" => "text");
     $options[] = array("name" => __('Category Exclude - Blog Page Template', 'woothemes'), "desc" => __('Specify a comma seperated list of category IDs or slugs that you\'d like to exclude from your \'Blog\' page template (eg: uncategorized).', 'woothemes'), "id" => $shortname . "_exclude_cats_blog", "std" => "", "type" => "text");
     /* Slider */
     $options[] = array("name" => __('Homepage Slider', 'woothemes'), "icon" => "slider", "type" => "heading");
     $options[] = array("name" => __('Enable Slider', 'woothemes'), "desc" => __('Enable the slider on the homepage.', 'woothemes'), "id" => $shortname . "_slider", "std" => "true", "type" => "checkbox");
     $options[] = array("name" => __('Slider Entries', 'woothemes'), "desc" => __('Select the number of entries that should appear in the home page slider.', 'woothemes'), "id" => $shortname . "_slider_entries", "std" => "3", "type" => "select", "options" => $other_entries);
     $options[] = array("name" => __('Effect', 'woothemes'), "desc" => __('Select the animation effect.', 'woothemes'), "id" => $shortname . "_slider_effect", "type" => "select2", "options" => array("slide" => __('Slide', 'woothemes'), "fade" => __('Fade', 'woothemes')));
     $options[] = array("name" => __('Hover Pause', 'woothemes'), "desc" => __('Hovering over slideshow will pause it', 'woothemes'), "id" => $shortname . "_slider_hover", "std" => "false", "type" => "checkbox");
     $options[] = array("name" => __('Animation Speed', 'woothemes'), "desc" => __('The time in <b>seconds</b> the animation between frames will take.', 'woothemes'), "id" => $shortname . "_slider_speed", "std" => "0.6", "type" => "select", "options" => array('0.0', '0.1', '0.2', '0.3', '0.4', '0.5', '0.6', '0.7', '0.8', '0.9', '1.0', '1.1', '1.2', '1.3', '1.4', '1.5', '1.6', '1.7', '1.8', '1.9', '2.0'));
     $options[] = array("name" => __('Auto Start', 'woothemes'), "desc" => __('Set the slider to start sliding automatically.', 'woothemes'), "id" => $shortname . "_slider_auto", "std" => "false", "type" => "checkbox");
     $options[] = array("name" => __('Auto Slide Interval', 'woothemes'), "desc" => __('The time in <b>seconds</b> each slide pauses for, before sliding to the next.', 'woothemes'), "id" => $shortname . "_slider_interval", "std" => "4", "type" => "select", "options" => array('1', '2', '3', '4', '5', '6', '7', '8', '9', '10'));
     $options[] = array("name" => __('Auto Height', 'woothemes'), "desc" => __('Set the slider to adjust automatically depending on the height of the current slide contents.', 'woothemes'), "id" => $shortname . "_slider_autoheight", "std" => "false", "type" => "checkbox");
     $options[] = array("name" => __('Show Title with Image Background', 'woothemes'), "desc" => __('Show the post title when using an image as slider background.', 'woothemes'), "id" => $shortname . "_slider_title", "std" => "false", "type" => "checkbox");
     $options[] = array("name" => __('Show Excerpt with Image Background', 'woothemes'), "desc" => __('Show the post excerpt when using an image as slider background.', 'woothemes'), "id" => $shortname . "_slider_content", "std" => "false", "type" => "checkbox");
     $options[] = array("name" => __('Next/Previous', 'woothemes'), "desc" => __('Select to display next/previous buttons.', 'woothemes'), "id" => $shortname . "_slider_nextprev", "std" => "false", "type" => "checkbox");
     $options[] = array("name" => __('Pagination', 'woothemes'), "desc" => __('Select to display pagination.', 'woothemes'), "id" => $shortname . "_slider_pagination", "std" => "true", "type" => "checkbox");
     /* Homepage */
     $options[] = array("name" => __('Homepage', 'woothemes'), "type" => "heading", 'icon' => 'homepage');
     $options[] = array("name" => __('Mini-Features Area', 'woothemes'), "desc" => __('Enable the front page Mini-Features features area.', 'woothemes'), "id" => $shortname . "_mini_features", "std" => "true", "type" => "checkbox");
     $options[] = array("name" => __('Homepage Content', 'woothemes'), "desc" => __('(Optional) Select a page that you\'d like to display on the front page.', 'woothemes'), "id" => $shortname . "_main_page", "std" => __('Select a page:', 'woothemes'), "type" => "select2", "options" => $woo_pages);
     /* Portfolio */
     $options[] = array("name" => __('Portfolio Settings', 'woothemes'), "icon" => "portfolio", "type" => "heading");
     $options[] = array("name" => __('Enable Single Portfolio Gallery', 'woothemes'), "desc" => __('Enable the gallery feature in the single portfolio page layout.', 'woothemes'), "id" => $shortname . "_portfolio_gallery", "std" => "true", "type" => "checkbox");
     $options[] = array("name" => __('Portfolio Items URL Base', 'woothemes'), "desc" => sprintf(__('The base of all portfolio item URLs (visit the %s screen after changing this setting).', 'woothemes'), '<a href="' . admin_url('options-permalink.php') . '">' . __('Settings- Permalinks', 'woothemes') . '</a>'), "id" => $shortname . "_portfolioitems_rewrite", "std" => "portfolio-items", "type" => "text");
     $options[] = array("name" => __('Exclude Galleries from the Portfolio Navigation', 'woothemes'), "desc" => __('Optionally exclude portfolio galleries from the portfolio gallery navigation switcher. Place the gallery slugs here, separated by commas <br />(eg: one,two,three)', 'woothemes'), "id" => $shortname . "_portfolio_excludenav", "std" => "", "type" => "text");
     $options[] = array("name" => __('Portfolio Thumbnail Dimensions', 'woothemes'), "desc" => __('Enter an integer value i.e. 250 for the image size.', 'woothemes'), "id" => $shortname . "_portfolio_thumb_dimensions", "std" => "", "type" => array(array('id' => $shortname . '_portfolio_thumb_width', 'type' => 'text', 'std' => 242, 'meta' => __('Width', 'woothemes')), array('id' => $shortname . '_portfolio_thumb_height', 'type' => 'text', 'std' => 160, 'meta' => __('Height', 'woothemes'))));
     $options[] = array("name" => __('Exclude Portfolio Items from Search Results', 'woothemes'), "desc" => __('Exclude portfolio items from results when searching your website.', 'woothemes'), "id" => $shortname . "_portfolio_excludesearch", "std" => "false", "type" => "checkbox");
     /* Testimonials */
     $options[] = array("name" => __('Feedback Settings', 'woothemes'), "icon" => "misc", "type" => "heading");
     $options[] = array("name" => __('Disable Feedback Manager', 'woothemes'), "desc" => __('Disable the feedback functionality.', 'woothemes'), "id" => $shortname . "_feedback_disable", "std" => "false", "type" => "checkbox");
     /* Dynamic Images */
     $options[] = array("name" => __('Dynamic Images', 'woothemes'), "type" => "heading", "icon" => "image");
     $options[] = array("name" => __('Dynamic Image Resizing', 'woothemes'), "desc" => "", "id" => $shortname . "_nxtthumb_notice", "std" => __('There are two alternative methods of dynamically resizing the thumbnails in the theme, <strong>nxt Post Thumbnail</strong> or <strong>TimThumb - Custom Settings panel</strong>. We recommend using nxt Post Thumbnail option.', 'woothemes'), "type" => "info");
     $options[] = array("name" => __('nxt Post Thumbnail', 'woothemes'), "desc" => __('Use NXTClass post thumbnail to assign a post thumbnail. Will enable the <strong>Featured Image panel</strong> in your post sidebar where you can assign a post thumbnail.', 'woothemes'), "id" => $shortname . "_post_image_support", "std" => "true", "class" => "collapsed", "type" => "checkbox");
     $options[] = array("name" => __('nxt Post Thumbnail - Dynamic Image Resizing', 'woothemes'), "desc" => __('The post thumbnail will be dynamically resized using native nxt resize functionality. <em>(Requires PHP 5.2+)</em>', 'woothemes'), "id" => $shortname . "_pis_resize", "std" => "true", "class" => "hidden", "type" => "checkbox");
     $options[] = array("name" => __('nxt Post Thumbnail - Hard Crop', 'woothemes'), "desc" => __('The post thumbnail will be cropped to match the target aspect ratio (only used if "Dynamic Image Resizing" is enabled).', 'woothemes'), "id" => $shortname . "_pis_hard_crop", "std" => "true", "class" => "hidden last", "type" => "checkbox");
     $options[] = array("name" => __('TimThumb - Custom Settings Panel', 'woothemes'), "desc" => sprintf(__('This will enable the %1$s (thumb.php) script which dynamically resizes images added through the <strong>custom settings panel below the post</strong>. Make sure your themes <em>cache</em> folder is writable. %2$s', 'woothemes'), '<a href="http://code.google.com/p/timthumb/">TimThumb</a>', '<a href="http://www.woothemes.com/2008/10/troubleshooting-image-resizer-thumbphp/">Need help?</a>'), "id" => $shortname . "_resize", "std" => "true", "type" => "checkbox");
     $options[] = array("name" => __('Automatic Image Thumbnail', 'woothemes'), "desc" => __('If no thumbnail is specifified then the first uploaded image in the post is used.', 'woothemes'), "id" => $shortname . "_auto_img", "std" => "false", "type" => "checkbox");
     $options[] = array("name" => __('Thumbnail Image Dimensions', 'woothemes'), "desc" => __('Enter an integer value i.e. 250 for the desired size which will be used when dynamically creating the images.', 'woothemes'), "id" => $shortname . "_image_dimensions", "std" => "", "type" => array(array('id' => $shortname . '_thumb_w', 'type' => 'text', 'std' => 100, 'meta' => __('Width', 'woothemes')), array('id' => $shortname . '_thumb_h', 'type' => 'text', 'std' => 100, 'meta' => __('Height', 'woothemes'))));
     $options[] = array("name" => __('Thumbnail Image alignment', 'woothemes'), "desc" => __('Select how to align your thumbnails with posts.', 'woothemes'), "id" => $shortname . "_thumb_align", "std" => "alignright", "type" => "radio", "options" => array("alignleft" => __('Left', 'woothemes'), "alignright" => __('Right', 'woothemes'), "aligncenter" => __('Center', 'woothemes')));
     $options[] = array("name" => __('Show thumbnail in Single Posts', 'woothemes'), "desc" => __('Show the attached image in the single post page.', 'woothemes'), "id" => $shortname . "_thumb_single", "class" => "collapsed", "std" => "false", "type" => "checkbox");
     $options[] = array("name" => __('Single Image Dimensions', 'woothemes'), "desc" => __('"Enter an integer value i.e. 250 for the image size. Max width is 576.', 'woothemes'), "id" => $shortname . "_image_dimensions", "std" => "", "class" => "hidden last", "type" => array(array('id' => $shortname . '_single_w', 'type' => 'text', 'std' => 200, 'meta' => __('Width', 'woothemes')), array('id' => $shortname . '_single_h', 'type' => 'text', 'std' => 200, 'meta' => __('Height', 'woothemes'))));
     $options[] = array("name" => __('Single Post Image alignment', 'woothemes'), "desc" => __('Select how to align your thumbnail with single posts.', 'woothemes'), "id" => $shortname . "_thumb_single_align", "std" => "alignright", "type" => "radio", "class" => "hidden", "options" => array("alignleft" => __('Left', 'woothemes'), "alignright" => __('Right', 'woothemes'), "aligncenter" => __('Center', 'woothemes')));
     $options[] = array("name" => __('Add thumbnail to RSS feed', 'woothemes'), "desc" => __('Add the the image uploaded via your Custom Settings to your RSS feed', 'woothemes'), "id" => $shortname . "_rss_thumb", "std" => "false", "type" => "checkbox");
     $options[] = array("name" => __('Enable Lightbox', 'woothemes'), "desc" => __('Enable the PrettyPhoto lighbox script on images within your website\'s content.', 'woothemes'), "id" => $shortname . "_enable_lightbox", "std" => "false", "type" => "checkbox");
     /* Footer */
     $options[] = array("name" => __('Footer Customization', 'woothemes'), "type" => "heading", "icon" => "footer");
     $options[] = array("name" => __('Title', 'woothemes'), "desc" => __('Add a heading for the widgetized footer regions.', 'woothemes'), "id" => $shortname . "_footer_title", "std" => '', "type" => "text");
     $url = get_template_directory_uri() . '/functions/images/';
     $options[] = array("name" => __('Footer Widget Areas', 'woothemes'), "desc" => __('Select how many footer widget areas you want to display.', 'woothemes'), "id" => $shortname . "_footer_sidebars", "std" => "4", "type" => "images", "options" => array('0' => $url . 'layout-off.png', '1' => $url . 'footer-widgets-1.png', '2' => $url . 'footer-widgets-2.png', '3' => $url . 'footer-widgets-3.png', '4' => $url . 'footer-widgets-4.png'));
     $options[] = array("name" => __('Custom Affiliate Link', 'woothemes'), "desc" => __('Add an affiliate link to the WooThemes logo in the footer of the theme.', 'woothemes'), "id" => $shortname . "_footer_aff_link", "std" => "", "type" => "text");
     $options[] = array("name" => __('Enable Custom Footer (Left)', 'woothemes'), "desc" => __('Activate to add the custom text below to the theme footer.', 'woothemes'), "id" => $shortname . "_footer_left", "std" => "false", "type" => "checkbox");
     $options[] = array("name" => __('Custom Text (Left)', 'woothemes'), "desc" => __('Custom HTML and Text that will appear in the footer of your theme.', 'woothemes'), "id" => $shortname . "_footer_left_text", "std" => "", "type" => "textarea");
     $options[] = array("name" => __('Enable Custom Footer (Right)', 'woothemes'), "desc" => __('Activate to add the custom text below to the theme footer.', 'woothemes'), "id" => $shortname . "_footer_right", "std" => "false", "type" => "checkbox");
     $options[] = array("name" => __('Custom Text (Right)', 'woothemes'), "desc" => __('Custom HTML and Text that will appear in the footer of your theme.', 'woothemes'), "id" => $shortname . "_footer_right_text", "std" => "", "type" => "textarea");
     /* Subscribe & Connect */
     $options[] = array("name" => __('Subscribe & Connect', 'woothemes'), "type" => "heading", "icon" => "connect");
     $options[] = array("name" => __('Enable Subscribe & Connect - Single Post', 'woothemes'), "desc" => sprintf(__('Enable the subscribe & connect area on single posts. You can also add this as a %1$s in your sidebar.', 'woothemes'), '<a href="' . home_url() . '/nxt-admin/widgets.php">widget</a>'), "id" => $shortname . "_connect", "std" => 'false', "type" => "checkbox");
     $options[] = array("name" => __('Subscribe Title', 'woothemes'), "desc" => __('Enter the title to show in your subscribe & connect area.', 'woothemes'), "id" => $shortname . "_connect_title", "std" => '', "type" => "text");
     $options[] = array("name" => __('Text', 'woothemes'), "desc" => __('Change the default text in this area.', 'woothemes'), "id" => $shortname . "_connect_content", "std" => '', "type" => "textarea");
     $options[] = array("name" => __('Subscribe By E-mail ID (Feedburner)', 'woothemes'), "desc" => __('Enter your <a href="http://www.google.com/support/feedburner/bin/answer.py?hl=en&answer=78982">Feedburner ID</a> for the e-mail subscription form.', 'woothemes'), "id" => $shortname . "_connect_newsletter_id", "std" => '', "type" => "text");
     $options[] = array("name" => __('Subscribe By E-mail to MailChimp', 'woothemes', 'woothemes'), "desc" => __('If you have a MailChimp account you can enter the <a href="http://woochimp.heroku.com" target="_blank">MailChimp List Subscribe URL</a> to allow your users to subscribe to a MailChimp List.', 'woothemes'), "id" => $shortname . "_connect_mailchimp_list_url", "std" => '', "type" => "text");
     $options[] = array("name" => __('Enable RSS', 'woothemes'), "desc" => __('Enable the subscribe and RSS icon.', 'woothemes'), "id" => $shortname . "_connect_rss", "std" => 'true', "type" => "checkbox");
     $options[] = array("name" => __('Twitter URL', 'woothemes'), "desc" => __('Enter your  <a href="http://www.twitter.com/">Twitter</a> URL e.g. http://www.twitter.com/woothemes', 'woothemes'), "id" => $shortname . "_connect_twitter", "std" => '', "type" => "text");
     $options[] = array("name" => __('Facebook URL', 'woothemes'), "desc" => __('Enter your  <a href="http://www.facebook.com/">Facebook</a> URL e.g. http://www.facebook.com/woothemes', 'woothemes'), "id" => $shortname . "_connect_facebook", "std" => '', "type" => "text");
     $options[] = array("name" => __('YouTube URL', 'woothemes'), "desc" => __('Enter your  <a href="http://www.youtube.com/">YouTube</a> URL e.g. http://www.youtube.com/woothemes', 'woothemes'), "id" => $shortname . "_connect_youtube", "std" => '', "type" => "text");
     $options[] = array("name" => __('Flickr URL', 'woothemes'), "desc" => __('Enter your  <a href="http://www.flickr.com/">Flickr</a> URL e.g. http://www.flickr.com/woothemes', 'woothemes'), "id" => $shortname . "_connect_flickr", "std" => '', "type" => "text");
     $options[] = array("name" => __('LinkedIn URL', 'woothemes'), "desc" => __('Enter your  <a href="http://www.www.linkedin.com.com/">LinkedIn</a> URL e.g. http://www.linkedin.com/in/woothemes', 'woothemes'), "id" => $shortname . "_connect_linkedin", "std" => '', "type" => "text");
     $options[] = array("name" => __('Delicious URL', 'woothemes'), "desc" => __('Enter your <a href="http://www.delicious.com/">Delicious</a> URL e.g. http://www.delicious.com/woothemes', 'woothemes'), "id" => $shortname . "_connect_delicious", "std" => '', "type" => "text");
     $options[] = array("name" => __('Google+ URL', 'woothemes'), "desc" => __('Enter your <a href="http://plus.google.com/">Google+</a> URL e.g. https://plus.google.com/104560124403688998123/', 'woothemes'), "id" => $shortname . "_connect_googleplus", "std" => '', "type" => "text");
     $options[] = array("name" => __('Enable Related Posts', 'woothemes'), "desc" => __('Enable related posts in the subscribe area. Uses posts with the same <strong>tags</strong> to find related posts. Note: Will not show in the Subscribe widget.', 'woothemes'), "id" => $shortname . "_connect_related", "std" => 'true', "type" => "checkbox");
     // Add extra options through function
     if (function_exists("woo_options_add")) {
         $options = woo_options_add($options);
     }
     if (get_option('woo_template') != $options) {
         update_option('woo_template', $options);
     }
     if (get_option('woo_themename') != $themename) {
         update_option('woo_themename', $themename);
     }
     if (get_option('woo_shortname') != $shortname) {
         update_option('woo_shortname', $shortname);
     }
     if (get_option('woo_manual') != $manualurl) {
         update_option('woo_manual', $manualurl);
     }
     // Woo Metabox Options
     // Start name with underscore to hide custom key from the user
     $woo_metaboxes = array();
     global $post;
     /* "portfolio" Custom Post Type. */
     if (get_post_type() == 'portfolio' || !get_post_type()) {
         $woo_metaboxes[] = array("name" => "portfolio-image", "label" => __('Portfolio Image', 'woothemes'), "type" => "upload", "desc" => __('Upload an image or enter an URL to your portfolio image', 'woothemes'));
         if (get_option('woo_resize') == "true") {
             $woo_metaboxes[] = array("name" => "_image_alignment", "std" => "c", "label" => __('Image Crop Alignment', 'woothemes'), "type" => "select2", "desc" => __('Select crop alignment for resized image', 'woothemes'), "options" => array("c" => __('Center', 'woothemes'), "t" => __('Top', 'woothemes'), "b" => __('Bottom', 'woothemes'), "l" => __('Left', 'woothemes'), "r" => __('Right', 'woothemes')));
         }
         $woo_metaboxes[] = array("name" => "embed", "std" => "", "label" => __('Video Embed Code', 'woothemes'), "type" => "textarea", "desc" => __('Enter the video embed code for your video (YouTube, Vimeo or similar). Will show instead of your image.', 'woothemes'));
         $woo_metaboxes['lightbox-description'] = array("name" => "lightbox-description", "label" => __('Custom Lightbox Description', 'woothemes'), "type" => "textarea", "desc" => sprintf(__('Enter an optional description to show in the %s for this portfolio item. This will be the description for all items in the gallery, if one is available.', 'woothemes'), '<a href="http://www.no-margin-for-errors.com/projects/prettyphoto-jquery-lightbox-clone/">' . __('PrettyPhoto lightbox', 'woothemes') . '</a>'));
         $woo_metaboxes['lightbox-url'] = array("name" => "lightbox-url", "label" => __('Lightbox URL', 'woothemes'), "type" => "text", "desc" => sprintf(__('Enter an optional URL to show in the %s for this portfolio item.', 'woothemes'), '<a href="http://www.no-margin-for-errors.com/projects/prettyphoto-jquery-lightbox-clone/">' . __('PrettyPhoto lightbox', 'woothemes') . '</a>'));
         $woo_metaboxes['testimonial'] = array("name" => "testimonial", "label" => __('Testimonial', 'woothemes'), "type" => "textarea", "desc" => __('Enter a testimonial from your client to be displayed on the single portfolio page', 'woothemes'));
         $woo_metaboxes['testimonial_author'] = array("name" => "testimonial_author", "label" => __('Testimonial Author', 'woothemes'), "type" => "text", "desc" => __('Enter the name of the author of the testimonial e.g. Joe Bloggs', 'woothemes'));
         $woo_metaboxes[] = array("name" => "url", "label" => __('URL', 'woothemes'), "type" => "text", "desc" => __('Enter URL of your clients site. (optional)', 'woothemes'));
     }
     //End portfolio
     if (get_post_type() == 'post' || !get_post_type()) {
         $woo_metaboxes[] = array("name" => "image", "label" => __('Image', 'woothemes'), "type" => "upload", "desc" => __('Upload an image or enter an URL.', 'woothemes'));
         if (get_option('woo_resize') == "true") {
             $woo_metaboxes[] = array("name" => "_image_alignment", "std" => "c", "label" => __('Image Crop Alignment', 'woothemes'), "type" => "select2", "desc" => __('Select crop alignment for resized image', 'woothemes'), "options" => array("c" => __('Center', 'woothemes'), "t" => __('Top', 'woothemes'), "b" => __('Bottom', 'woothemes'), "l" => __('Left', 'woothemes'), "r" => __('Right', 'woothemes')));
         }
         $woo_metaboxes[] = array("name" => "embed", "std" => "", "label" => __('Video Embed Code', 'woothemes'), "type" => "textarea", "desc" => __('Enter the video embed code for your video (YouTube, Vimeo or similar)', 'woothemes'));
     }
     // End post
     if (get_post_type() == 'slide' || !get_post_type()) {
         $woo_metaboxes[] = array("name" => "image", "label" => __('Slide Image', 'woothemes'), "type" => "upload", "desc" => __('Upload an image or enter an URL to your slide image', 'woothemes'));
         $woo_metaboxes[] = array("name" => "embed", "std" => "", "label" => __('Video Embed Code', 'woothemes'), "type" => "textarea", "desc" => __('Enter the video embed code for your video (YouTube, Vimeo or similar). Will show instead of your image.', 'woothemes'));
         $woo_metaboxes[] = array("name" => "url", "label" => __('URL', 'woothemes'), "type" => "text", "desc" => __('Enter URL if you want to add a link to the uploaded image and title. (optional)', 'woothemes'));
     }
     //End slide
     if (get_post_type() == 'infobox' || !get_post_type()) {
         $woo_metaboxes[] = array("name" => "mini", "label" => __('Mini-features Icon', 'woothemes'), "type" => "upload", "desc" => __('Upload icon for use with the Mini-Feature on the homepage (optimal size: 32x32px) (optional)', 'woothemes'));
         $woo_metaboxes[] = array("name" => "mini_excerpt", "label" => __('Mini-features Excerpt', 'woothemes'), "type" => "textarea", "desc" => __('Enter the text to show in your Mini-Feature.', 'woothemes'));
         $woo_metaboxes[] = array("name" => "mini_readmore", "std" => "", "label" => __('Mini-features URL', 'woothemes'), "type" => "text", "desc" => __('Add an URL for your Read More button in your Mini-Feature on homepage (optional)', 'woothemes'));
     }
     // End mini
     if (get_post_type() == 'feedback' || !get_post_type()) {
         $woo_metaboxes['feedback_author'] = array("name" => "feedback_author", "label" => __('Feedback Author', 'woothemes'), "type" => "text", "desc" => __('Enter the name of the author of the feedback e.g. Joe Bloggs', 'woothemes'));
         $woo_metaboxes['feedback_url'] = array("name" => "feedback_url", "label" => __('Feedback URL', 'woothemes'), "type" => "text", "desc" => __('(optional) Enter the URL to the feedback author e.g. http://www.woothemes.com', 'woothemes'));
     }
     // End feedback
     if (in_array(get_post_type(), array('page', 'post', 'portfolio')) || !get_post_type()) {
         $woo_metaboxes[] = array("name" => "_layout", "std" => "normal", "label" => __('Layout', 'woothemes'), "type" => "images", "desc" => __('Select the layout you want on this specific post/page.', 'woothemes'), "options" => array('layout-default' => $url . 'layout-off.png', 'layout-full' => get_template_directory_uri() . '/functions/images/' . '1c.png', 'layout-left-content' => get_template_directory_uri() . '/functions/images/' . '2cl.png', 'layout-right-content' => get_template_directory_uri() . '/functions/images/' . '2cr.png'));
     }
     // Add extra metaboxes through function
     if (function_exists("woo_metaboxes_add")) {
         $woo_metaboxes = woo_metaboxes_add($woo_metaboxes);
     }
     if (get_option('woo_custom_template') != $woo_metaboxes) {
         update_option('woo_custom_template', $woo_metaboxes);
     }
 }