PageRenderTime 47ms CodeModel.GetById 18ms RepoModel.GetById 0ms app.codeStats 0ms

/wp-content/themes/bladencountyrecords/includes/theme-options.php

https://gitlab.com/blueprintmrk/bladencountyrecords
PHP | 625 lines | 544 code | 67 blank | 14 comment | 14 complexity | 27c8bcd62b90be522af7ff9fa6075070 MD5 | raw file
  1. <?php
  2. //Enable WooSEO on these custom Post types
  3. $seo_post_types = array('post','page');
  4. define("SEOPOSTTYPES", serialize($seo_post_types));
  5. //Global options setup
  6. add_action('init','woo_global_options');
  7. function woo_global_options(){
  8. // Populate WooThemes option in array for use in theme
  9. global $woo_options;
  10. $woo_options = get_option('woo_options');
  11. }
  12. add_action('admin_head','woo_options');
  13. if (!function_exists('woo_options')) {
  14. function woo_options(){
  15. // VARIABLES
  16. $themename = "Bladen County";
  17. $manualurl = 'http://www.woothemes.com/support/theme-documentation/elefolio/';
  18. $shortname = "project";
  19. $GLOBALS['template_path'] = get_bloginfo('template_directory');
  20. //Access the WordPress Categories via an Array
  21. $woo_categories = array();
  22. $woo_categories_obj = get_categories('hide_empty=0');
  23. foreach ($woo_categories_obj as $woo_cat) {
  24. $woo_categories[$woo_cat->cat_ID] = $woo_cat->cat_name;}
  25. $categories_tmp = array_unshift($woo_categories, "Select a category:");
  26. //Access the WordPress Pages via an Array
  27. $woo_pages = array();
  28. $woo_pages_obj = get_pages('sort_column=post_parent,menu_order');
  29. foreach ($woo_pages_obj as $woo_page) {
  30. $woo_pages[$woo_page->ID] = $woo_page->post_name; }
  31. $woo_pages_tmp = array_unshift($woo_pages, "Select a page:");
  32. // Image Alignment radio box
  33. $options_thumb_align = array("alignleft" => "Left","alignright" => "Right","aligncenter" => "Center");
  34. // Image Links to Options
  35. $options_image_link_to = array("image" => "The Image","post" => "The Post");
  36. //Testing
  37. $options_select = array("one","two","three","four","five");
  38. $options_radio = array("one" => "One","two" => "Two","three" => "Three","four" => "Four","five" => "Five");
  39. //URL Shorteners
  40. if (_iscurlinstalled()) {
  41. $options_select = array("Off","TinyURL","Bit.ly");
  42. $short_url_msg = 'Select the URL shortening service you would like to use.';
  43. } else {
  44. $options_select = array("Off");
  45. $short_url_msg = '<strong>cURL was not detected on your server, and is required in order to use the URL shortening services.</strong>';
  46. }
  47. //Stylesheets Reader
  48. $alt_stylesheet_path = TEMPLATEPATH . '/styles/';
  49. $alt_stylesheets = array();
  50. if ( is_dir($alt_stylesheet_path) ) {
  51. if ($alt_stylesheet_dir = opendir($alt_stylesheet_path) ) {
  52. while ( ($alt_stylesheet_file = readdir($alt_stylesheet_dir)) !== false ) {
  53. if(stristr($alt_stylesheet_file, ".css") !== false) {
  54. $alt_stylesheets[] = $alt_stylesheet_file;
  55. }
  56. }
  57. }
  58. }
  59. //More Options
  60. $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");
  61. $body_repeat = array("no-repeat","repeat-x","repeat-y","repeat");
  62. $body_pos = array("top left","top center","top right","center left","center center","center right","bottom left","bottom center","bottom right");
  63. // THIS IS THE DIFFERENT FIELDS
  64. $options = array();
  65. $options[] = array( "name" => "General Settings",
  66. "type" => "heading",
  67. "icon" => "general");
  68. $options[] = array( "name" => "Theme Stylesheet",
  69. "desc" => "Select your themes alternative color scheme.",
  70. "id" => $shortname."_alt_stylesheet",
  71. "std" => "default.css",
  72. "type" => "select",
  73. "options" => $alt_stylesheets);
  74. $options[] = array( "name" => "Custom Logo",
  75. "desc" => "Upload a logo for your theme, or specify an image URL directly.",
  76. "id" => $shortname."_logo",
  77. "std" => "",
  78. "type" => "upload");
  79. $options[] = array( "name" => "Text Title",
  80. "desc" => "Enable text-based Site Title and Tagline. Setup title & tagline in Settings->General.",
  81. "id" => $shortname."_texttitle",
  82. "std" => "false",
  83. "class" => "collapsed",
  84. "type" => "checkbox");
  85. $options[] = array( "name" => "Site Title",
  86. "desc" => "Change the site title (must have 'Text Title' option enabled).",
  87. "id" => $shortname."_font_site_title",
  88. "std" => array('size' => '40','unit' => 'px','face' => 'Impact','style' => '','color' => '#222222'),
  89. "class" => "hidden",
  90. "type" => "typography");
  91. $options[] = array( "name" => "Site Description",
  92. "desc" => "Change the site description (must have 'Text Title' option enabled).",
  93. "id" => $shortname."_font_tagline",
  94. "std" => array('size' => '14','unit' => 'px','face' => 'Georgia','style' => 'italic','color' => '#999999'),
  95. "class" => "hidden last",
  96. "type" => "typography");
  97. $options[] = array( "name" => "Custom Favicon",
  98. "desc" => "Upload a 16px x 16px <a href='http://www.faviconr.com/'>ico image</a> that will represent your website's favicon.",
  99. "id" => $shortname."_custom_favicon",
  100. "std" => "",
  101. "type" => "upload");
  102. $options[] = array( "name" => "Tracking Code",
  103. "desc" => "Paste your Google Analytics (or other) tracking code here. This will be added into the footer template of your theme.",
  104. "id" => $shortname."_google_analytics",
  105. "std" => "",
  106. "type" => "textarea");
  107. $options[] = array( "name" => "RSS URL",
  108. "desc" => "Enter your preferred RSS URL. (Feedburner or other)",
  109. "id" => $shortname."_feed_url",
  110. "std" => "",
  111. "type" => "text");
  112. $options[] = array( "name" => "E-Mail URL",
  113. "desc" => "Enter your preferred E-mail subscription URL. (Feedburner or other)",
  114. "id" => $shortname."_subscribe_email",
  115. "std" => "",
  116. "type" => "text");
  117. $options[] = array( "name" => "Contact Form E-Mail",
  118. "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.",
  119. "id" => $shortname."_contactform_email",
  120. "std" => "",
  121. "type" => "text");
  122. $options[] = array( "name" => "Custom CSS",
  123. "desc" => "Quickly add some CSS to your theme by adding it to this block.",
  124. "id" => $shortname."_custom_css",
  125. "std" => "",
  126. "type" => "textarea");
  127. $options[] = array( "name" => "Post/Page Comments",
  128. "desc" => "Select if you want to enable/disable comments on posts and/or pages. ",
  129. "id" => $shortname."_comments",
  130. "type" => "select2",
  131. "options" => array("post" => "Posts Only", "page" => "Pages Only", "both" => "Pages / Posts", "none" => "None") );
  132. $options[] = array( "name" => "Post Content",
  133. "desc" => "Select if you want to show the full content or the excerpt on posts. ",
  134. "id" => $shortname."_post_content",
  135. "type" => "select2",
  136. "options" => array("excerpt" => "The Excerpt", "content" => "Full Content" ) );
  137. $options[] = array( "name" => "Styling Options",
  138. "type" => "heading",
  139. "icon" => "styling");
  140. $options[] = array( "name" => "Body Background Color",
  141. "desc" => "Pick a custom color for background color of the theme e.g. #697e09",
  142. "id" => "woo_body_color",
  143. "std" => "",
  144. "type" => "color");
  145. $options[] = array( "name" => "Body background image",
  146. "desc" => "Upload an image for the theme's background",
  147. "id" => $shortname."_body_img",
  148. "std" => "",
  149. "type" => "upload");
  150. $options[] = array( "name" => "Background image repeat",
  151. "desc" => "Select how you would like to repeat the background-image",
  152. "id" => $shortname."_body_repeat",
  153. "std" => "no-repeat",
  154. "type" => "select",
  155. "options" => $body_repeat);
  156. $options[] = array( "name" => "Background image position",
  157. "desc" => "Select how you would like to position the background",
  158. "id" => $shortname."_body_pos",
  159. "std" => "top",
  160. "type" => "select",
  161. "options" => $body_pos);
  162. $options[] = array( "name" => "Link Color",
  163. "desc" => "Pick a custom color for links or add a hex color code e.g. #697e09",
  164. "id" => "woo_link_color",
  165. "std" => "",
  166. "type" => "color");
  167. $options[] = array( "name" => "Link Hover Color",
  168. "desc" => "Pick a custom color for links hover or add a hex color code e.g. #697e09",
  169. "id" => "woo_link_hover_color",
  170. "std" => "",
  171. "type" => "color");
  172. $options[] = array( "name" => "Button Color",
  173. "desc" => "Pick a custom color for buttons or add a hex color code e.g. #697e09",
  174. "id" => "woo_button_color",
  175. "std" => "",
  176. "type" => "color");
  177. $options[] = array( "name" => "Typography",
  178. "type" => "heading",
  179. "icon" => "typography");
  180. $options[] = array( "name" => "Enable Custom Typography",
  181. "desc" => "Enable the use of custom typography for your site. Custom styling will be output in your sites HEAD.",
  182. "id" => $shortname."_typography",
  183. "std" => "false",
  184. "type" => "checkbox");
  185. $options[] = array( "name" => "General Typography",
  186. "desc" => "Change the general font.",
  187. "id" => $shortname."_font_body",
  188. "std" => array('size' => '12','unit' => 'px','face' => 'Arial','style' => '','color' => '#555555'),
  189. "type" => "typography");
  190. $options[] = array( "name" => "About (Homepage)",
  191. "desc" => "Change the about text font.",
  192. "id" => $shortname."_font_about",
  193. "std" => array('size' => '32','unit' => 'px','face' => 'Georgia','style' => '','color' => '#126661'),
  194. "type" => "typography");
  195. $options[] = array( "name" => "Navigation",
  196. "desc" => "Change the navigation font.",
  197. "id" => $shortname."_font_nav",
  198. "std" => array('size' => '15','unit' => 'px','face' => 'Georgia','style' => '','color' => '#151515'),
  199. "type" => "typography");
  200. $options[] = array( "name" => "Post Title",
  201. "desc" => "Change the post title.",
  202. "id" => $shortname."_font_post_title",
  203. "std" => array('size' => '24','unit' => 'px','face' => 'Georgia','style' => 'bold','color' => '#222222'),
  204. "type" => "typography");
  205. $options[] = array( "name" => "Post Meta",
  206. "desc" => "Change the post meta.",
  207. "id" => $shortname."_font_post_meta",
  208. "std" => array('size' => '14','unit' => 'px','face' => 'Georgia','style' => '','color' => '#999999'),
  209. "type" => "typography");
  210. $options[] = array( "name" => "Post Entry",
  211. "desc" => "Change the post entry.",
  212. "id" => $shortname."_font_post_entry",
  213. "std" => array('size' => '13','unit' => 'px','face' => 'Arial','style' => '','color' => '#555555'),
  214. "type" => "typography");
  215. $options[] = array( "name" => "Widget Titles",
  216. "desc" => "Change the widget titles.",
  217. "id" => $shortname."_font_widget_titles",
  218. "std" => array('size' => '16','unit' => 'px','face' => 'Georgia','style' => 'bold','color' => '#555555'),
  219. "type" => "typography");
  220. //Header
  221. $options[] = array( "name" => "Homepage",
  222. "type" => "heading",
  223. "icon" => "homepage");
  224. $options[] = array( "name" => "Enable About Section",
  225. "desc" => "Show a welcome message in your header and add social media icons.",
  226. "id" => $shortname."_about",
  227. "std" => "true",
  228. "type" => "checkbox");
  229. $options[] = array( "name" => "About Message",
  230. "desc" => "Enter an about message that will show just below the logo",
  231. "id" => $shortname."_header_bio",
  232. "std" => "Edit this welcome message in your options panel",
  233. "type" => "textarea");
  234. $options[] = array( "name" => "Facebook",
  235. "desc" => "Enter your profile url",
  236. "id" => $shortname."_social_facebook",
  237. "std" => "",
  238. "type" => "text");
  239. $options[] = array( "name" => "Linkedin",
  240. "desc" => "Enter your profile url",
  241. "id" => $shortname."_social_linkedin",
  242. "std" => "",
  243. "type" => "text");
  244. $options[] = array( "name" => "Twitter",
  245. "desc" => "Enter your profile url",
  246. "id" => $shortname."_social_twitter",
  247. "std" => "",
  248. "type" => "text");
  249. $options[] = array( "name" => "Portfolio",
  250. "icon" => "portfolio",
  251. "type" => "heading");
  252. $options[] = array( "name" => "Enable Portfolio",
  253. "desc" => "Enable the portfolio section below the about section. Add portfolio posts using the 'Portfolio' custom post type.",
  254. "id" => $shortname."_portfolio",
  255. "std" => "true",
  256. "type" => "checkbox");
  257. $options[] = array( "name" => "Number of portfolio items",
  258. "id" => $shortname."_portfolio_number",
  259. "std" => "4",
  260. "type" => "select",
  261. "options" => $other_entries);
  262. $options[] = array( "name" => "Portfolio Tags",
  263. "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.",
  264. "id" => $shortname."_portfolio_tags",
  265. "std" => "",
  266. "type" => "text");
  267. $options[] = array( "name" => "Tumblog Setup",
  268. "icon" => "tumblog",
  269. "type" => "heading");
  270. $content_option_array = array( 'taxonomy' => 'Taxonomy',
  271. 'post_format' => 'Post Formats'
  272. );
  273. $options[] = array( "name" => "Tumblog Content Method",
  274. "desc" => "Select if you would like to use a Taxonomy of Post Formats to categorize your Tumblog content.",
  275. "id" => $shortname."_tumblog_content_method",
  276. "std" => "post_format",
  277. "type" => "select2",
  278. "options" => $content_option_array);
  279. $options[] = array( "name" => "Use Custom Tumblog RSS Feed",
  280. "desc" => "Replaces the default WordPress RSS feed output with Tumblog RSS output.",
  281. "id" => $shortname."_custom_rss",
  282. "std" => "true",
  283. "type" => "checkbox");
  284. $options[] = array( "name" => "Full Content Home",
  285. "desc" => "Show the full content in posts on homepage instead of the excerpt.",
  286. "id" => $shortname."_home_content",
  287. "std" => "false",
  288. "type" => "checkbox");
  289. $options[] = array( "name" => "Full Content Archive",
  290. "desc" => "Show the full content in posts on archive pages instead of the excerpt.",
  291. "id" => $shortname."_archive_content",
  292. "std" => "false",
  293. "type" => "checkbox");
  294. $options[] = array( "name" => "Images Link to",
  295. "desc" => "Select where your Tumblog Images will link to when clicked.",
  296. "id" => $shortname."_image_link_to",
  297. "std" => "post",
  298. "type" => "radio",
  299. "options" => $options_image_link_to);
  300. $options[] = array( "name" => "URL Shortening Service",
  301. "desc" => $short_url_msg,
  302. "id" => $shortname."_url_shorten",
  303. "std" => "Select a Service:",
  304. "type" => "select",
  305. "options" => $options_select);
  306. $options[] = array( "name" => "Bit.ly Login Name",
  307. "desc" => "Your Bit.ly login name - get this here <a href='http://bit.ly/account/' target='_blank'>http://bit.ly/account/</a>",
  308. "id" => $shortname."_bitly_api_login",
  309. "std" => "",
  310. "type" => "text");
  311. $options[] = array( "name" => "Bit.ly API Key",
  312. "desc" => "Your Bit.ly API Key - get this here <a href='http://bit.ly/account/' target='_blank'>http://bit.ly/account/</a>",
  313. "id" => $shortname."_bitly_api_key",
  314. "std" => "",
  315. "type" => "text");
  316. $options[] = array( "name" => "Dynamic Images",
  317. "type" => "heading",
  318. "icon" => "image");
  319. $options[] = array( "name" => "Enable WordPress Post Thumbnail Support",
  320. "desc" => "Use WordPress post thumbnail support to assign a post thumbnail.",
  321. "id" => $shortname."_post_image_support",
  322. "std" => "true",
  323. "class" => "collapsed",
  324. "type" => "checkbox");
  325. $options[] = array( "name" => "Dynamically Resize Post Thumbnail",
  326. "desc" => "The post thumbnail will be dynamically resized using native WP resize functionality. <em>(Requires PHP 5.2+)</em>",
  327. "id" => $shortname."_pis_resize",
  328. "std" => "true",
  329. "class" => "hidden",
  330. "type" => "checkbox");
  331. $options[] = array( "name" => "Hard Crop Post Thumbnail",
  332. "desc" => "The image will be cropped to match the target aspect ratio.",
  333. "id" => $shortname."_pis_hard_crop",
  334. "std" => "true",
  335. "class" => "hidden last",
  336. "type" => "checkbox");
  337. $options[] = array( "name" => "Enable Dynamic Image Resizer",
  338. "desc" => "This will enable the thumb.php script which dynamically resizes images on your site.",
  339. "id" => $shortname."_resize",
  340. "std" => "true",
  341. "type" => "checkbox");
  342. $options[] = array( "name" => "Dynamic Image Height",
  343. "desc" => "If this is enabled, the height of your images will be dynamically calculated based on the width's as set below.",
  344. "id" => $shortname."_dynamic_img_height",
  345. "std" => "true",
  346. "type" => "checkbox");
  347. $options[] = array( "name" => "Thumbnail Image Dimensions",
  348. "desc" => "Enter an integer value i.e. 250 for the desired size which will be used when dynamically creating the images.",
  349. "id" => $shortname."_image_dimensions",
  350. "std" => "",
  351. "type" => array(
  352. array( 'id' => $shortname. '_thumb_w',
  353. 'type' => 'text',
  354. 'std' => 550,
  355. 'meta' => 'Width'),
  356. array( 'id' => $shortname. '_thumb_h',
  357. 'type' => 'text',
  358. 'std' => 412,
  359. 'meta' => 'Height')
  360. ));
  361. $options[] = array( "name" => "Thumbnail Image alignment",
  362. "desc" => "Select how to align your thumbnails with posts.",
  363. "id" => $shortname."_thumb_align",
  364. "std" => "aligncenter",
  365. "type" => "radio",
  366. "options" => $options_thumb_align);
  367. $options[] = array( "name" => "Show thumbnail in Single Posts",
  368. "desc" => "Show the attached image in the single post page.",
  369. "id" => $shortname."_thumb_single",
  370. "class" => "collapsed",
  371. "std" => "true",
  372. "type" => "checkbox");
  373. $options[] = array( "name" => "Single Image Dimensions",
  374. "desc" => "Enter an integer value i.e. 250 for the image size. Max width is 576.",
  375. "id" => $shortname."_image_dimensions",
  376. "std" => "",
  377. "class" => "hidden last",
  378. "type" => array(
  379. array( 'id' => $shortname. '_single_w',
  380. 'type' => 'text',
  381. 'std' => 550,
  382. 'meta' => 'Width'),
  383. array( 'id' => $shortname. '_single_h',
  384. 'type' => 'text',
  385. 'std' => 412,
  386. 'meta' => 'Height')
  387. ));
  388. $options[] = array( "name" => "Single Post Image alignment",
  389. "desc" => "Select how to align your thumbnail with single posts.",
  390. "id" => $shortname."_thumb_single_align",
  391. "std" => "aligncenter",
  392. "type" => "radio",
  393. "class" => "hidden",
  394. "options" => $options_thumb_align);
  395. //Footer
  396. $options[] = array( "name" => "Footer Customization",
  397. "type" => "heading",
  398. "icon" => "footer");
  399. $options[] = array( "name" => "Custom Affiliate Link",
  400. "desc" => "Add an affiliate link to the WooThemes logo in the footer of the theme.",
  401. "id" => $shortname."_footer_aff_link",
  402. "std" => "",
  403. "type" => "text");
  404. $options[] = array( "name" => "Enable Custom Footer (Left)",
  405. "desc" => "Activate to add the custom text below to the theme footer.",
  406. "id" => $shortname."_footer_left",
  407. "class" => "collapsed",
  408. "std" => "false",
  409. "type" => "checkbox");
  410. $options[] = array( "name" => "Custom Text (Left)",
  411. "desc" => "Custom HTML and Text that will appear in the footer of your theme.",
  412. "id" => $shortname."_footer_left_text",
  413. "class" => "hidden last",
  414. "std" => "<p></p>",
  415. "type" => "textarea");
  416. $options[] = array( "name" => "Enable Custom Footer (Right)",
  417. "desc" => "Activate to add the custom text below to the theme footer.",
  418. "id" => $shortname."_footer_right",
  419. "class" => "collapsed",
  420. "std" => "false",
  421. "type" => "checkbox");
  422. $options[] = array( "name" => "Custom Text (Right)",
  423. "desc" => "Custom HTML and Text that will appear in the footer of your theme.",
  424. "id" => $shortname."_footer_right_text",
  425. "class" => "hidden last",
  426. "std" => "<p></p>",
  427. "type" => "textarea");
  428. // Add extra options through function
  429. if ( function_exists("woo_options_add") )
  430. $options = woo_options_add($options);
  431. if ( get_option('woo_template') != $options) update_option('woo_template',$options);
  432. if ( get_option('woo_themename') != $themename) update_option('woo_themename',$themename);
  433. if ( get_option('woo_shortname') != $shortname) update_option('woo_shortname',$shortname);
  434. if ( get_option('woo_manual') != $manualurl) update_option('woo_manual',$manualurl);
  435. // Woo Metabox Options
  436. // Start name with underscore to hide custom key from the user
  437. $woo_metaboxes = array();
  438. global $post;
  439. if ( !get_post_type() ) {
  440. $woo_metaboxes[] = array (
  441. "name" => "image",
  442. "label" => "Image",
  443. "type" => "upload",
  444. "desc" => "Upload file here..."
  445. );
  446. $woo_metaboxes[] = array (
  447. "name" => "video-embed",
  448. "label" => "Embed Code (Videos)",
  449. "type" => "textarea",
  450. "desc" => "Add embed code for video services like Youtube or Vimeo"
  451. );
  452. $woo_metaboxes[] = array (
  453. "name" => "quote-author",
  454. "std" => "Unknown",
  455. "label" => "Quote Author",
  456. "type" => "text",
  457. "desc" => "Enter the name of the Quote Author."
  458. );
  459. $woo_metaboxes[] = array (
  460. "name" => "quote-url",
  461. "std" => "http://",
  462. "label" => "Link to Quote",
  463. "type" => "text",
  464. "desc" => "Enter the url/web address of the Quote if available."
  465. );
  466. $woo_metaboxes[] = array (
  467. "name" => "quote-copy",
  468. "std" => "Unknown",
  469. "label" => "Quote",
  470. "type" => "textarea",
  471. "desc" => "Enter the Quote."
  472. );
  473. $woo_metaboxes[] = array (
  474. "name" => "audio",
  475. "std" => "http://",
  476. "label" => "Audio URL",
  477. "type" => "text",
  478. "desc" => "Enter the url/web address of the Audio file."
  479. );
  480. $woo_metaboxes[] = array (
  481. "name" => "link-url",
  482. "std" => "http://",
  483. "label" => "Link URL",
  484. "type" => "text",
  485. "desc" => "Enter the url/web address of the Link."
  486. );
  487. } // End post
  488. if ( get_post_type() == 'portfolio' || !get_post_type() ) {
  489. $woo_metaboxes[] = array ( "name" => "portfolio-image",
  490. "label" => "Portfolio Image",
  491. "type" => "upload",
  492. "desc" => "Upload an image or enter an URL to your portfolio image");
  493. if ( get_option('woo_resize') == "true" ) {
  494. $woo_metaboxes[] = array ( "name" => "_image_alignment",
  495. "std" => "Center",
  496. "label" => "Image Crop Alignment",
  497. "type" => "select2",
  498. "desc" => "Select crop alignment for resized image",
  499. "options" => array( "c" => "Center",
  500. "t" => "Top",
  501. "b" => "Bottom",
  502. "l" => "Left",
  503. "r" => "Right"));
  504. }
  505. $woo_metaboxes[] = array ( "name" => "embed",
  506. "std" => "",
  507. "label" => "Video Embed Code",
  508. "type" => "textarea",
  509. "desc" => "Enter the video embed code for your video (YouTube, Vimeo or similar). Will show instead of your image.");
  510. }
  511. // Add extra metaboxes through function
  512. if ( function_exists("woo_metaboxes_add") )
  513. $woo_metaboxes = woo_metaboxes_add($woo_metaboxes);
  514. if ( get_option('woo_custom_template') != $woo_metaboxes) update_option('woo_custom_template',$woo_metaboxes);
  515. }
  516. }
  517. ?>