예제 #1
0
 function section_persistent()
 {
     /* 
     	Create Custom Post Type 
     */
     $args = array('label' => __('Boxes', 'pagelines'), 'singular_label' => __('Box', 'pagelines'), 'description' => 'For creating boxes in box type layouts.');
     $taxonomies = array("box-sets" => array("label" => __('Box Sets', 'pagelines'), "singular_label" => __('Box Set', 'pagelines')));
     $columns = array("cb" => "<input type=\"checkbox\" />", "title" => "Title", "bdescription" => "Text", "bmedia" => "Media", "box-sets" => "Box Sets");
     $column_value_function = 'box_column_display';
     $this->post_type = new PageLinesPostType($this->id, $args, $taxonomies, $columns, $column_value_function);
     /* Set default posts if none are present */
     $this->post_type->set_default_posts('pagelines_default_boxes');
     /*
     	Meta Options
     */
     /*
     	Create meta fields for the post type
     */
     $type_meta_array = array('the_box_icon' => array('type' => 'image_upload', 'title' => 'Box Image', 'desc' => 'Upload an image for the box.<br/> Depending on your settings this image will be used as an icon, or splash image; so desired size may vary.'), 'the_box_icon_link' => array('type' => 'text', 'title' => 'Box Link (Optional)', 'desc' => 'Make the box image and title clickable by adding a link here (optional)...'));
     $post_types = array($this->id);
     $type_metapanel_settings = array('id' => 'boxes-metapanel', 'name' => THEMENAME . " Box Options", 'posttype' => $post_types);
     global $boxes_meta_panel;
     $boxes_meta_panel = new PageLinesMetaPanel($type_metapanel_settings);
     $type_metatab_settings = array('id' => 'boxes-type-metatab', 'name' => "Box Setup Options", 'icon' => $this->icon);
     $boxes_meta_panel->register_tab($type_metatab_settings, $type_meta_array);
     /*
     	Build Ind. Page and Post Options
     */
     $metatab_array = array('box_set' => array('type' => 'select_taxonomy', 'taxonomy_id' => "box-sets", 'title' => 'Select Box Set To Show', 'desc' => 'If you are using the box section, select the box set you would like to show on this page.'), 'box_col_number' => array('type' => 'select_count', 'count_number' => '5', 'count_start' => '2', 'inputlabel' => 'Number of Feature Box Columns', 'title' => 'Box Columns', 'label' => "Select the number of columns to show boxes in.", 'desc' => "The number you select here will be the number of boxes listed in a row on a page. Note: This won't work on the blog page (use the global option)."), 'box_thumb_type' => array('type' => 'select', 'selectvalues' => array('inline_thumbs' => array("name" => "Image At Left"), 'top_thumbs' => array("name" => "Image On Top"), 'only_thumbs' => array("name" => "Only The Image, No Text")), 'title' => 'Box Thumb Position', 'desc' => 'Choose between thumbs on left and thumbs on top of boxes.'), 'box_thumb_size' => array('type' => 'text', 'size' => 'small', 'title' => 'Box Icon Size (in Pixels)', 'label' => "Enter the icon size in pixels", 'desc' => "Select the default icon size in pixels, set the images when creating new boxes."), 'box_items' => array('type' => 'text', 'size' => 'small', 'inputlabel' => 'Maximum Boxes To Show On Page', 'title' => 'Max Number of Boxes', 'desc' => "Select the max number of boxes to show on this page (overrides default)."));
     $metatab_settings = array('id' => 'fboxes_meta', 'name' => "Boxes Section", 'icon' => $this->icon);
     register_metatab($metatab_settings, $metatab_array);
 }
예제 #2
0
 function section_persistent()
 {
     /* 
     	Create Custom Post Type 
     */
     $args = array('label' => __('Banners', 'pagelines'), 'singular_label' => __('Banner', 'pagelines'), 'description' => 'For creating banners in banner section layouts.');
     $taxonomies = array("banner-sets" => array("label" => __('Banner Sets', 'pagelines'), "singular_label" => __('Banner Set', 'pagelines')));
     $columns = array("cb" => "<input type=\"checkbox\" />", "title" => "Title", "banner-description" => "Text", "banner-media" => "Media", "banner-sets" => "Banner Sets");
     $column_value_function = 'banner_column_display';
     $this->post_type = new PageLinesPostType($this->id, $args, $taxonomies, $columns, $column_value_function);
     /* Set default posts if none are present */
     $this->post_type->set_default_posts('pagelines_default_banners');
     /*
     	Meta Options
     */
     /*
     	Create meta fields for the post type
     */
     $type_meta_array = array('the_banner_image' => array('version' => 'pro', 'type' => 'image_upload', 'title' => 'Banner Media', 'desc' => 'Upload an image for the banner.'), 'the_banner_media' => array('version' => 'pro', 'type' => 'textarea', 'title' => 'Banner Media', 'desc' => 'Add HTML Media for the banner, e.g. Youtube embed code. This option is used if there is no image uploaded.'), 'banner_text_width' => array('version' => 'pro', 'type' => 'text', 'size' => 'small', 'title' => 'Banner Text Width (In %)', 'desc' => 'Set the width of the text area as a percentage of full content width.  The media area will fill the rest.'), 'banner_align' => array('version' => 'pro', 'type' => 'select', 'selectvalues' => array('banner_right' => array("name" => "Banner Right"), 'banner_left' => array("name" => "Banner Left")), 'title' => 'Banner Alignment', 'desc' => 'Put the media on the right or the left?'), 'banner_text_padding' => array('version' => 'pro', 'type' => 'text', 'size' => 'small', 'title' => 'Banner Text Padding', 'desc' => '(optional) Set the padding for the text area. Use CSS shorthand, for example:<strong> 25px 30px 25px 35px</strong>; for top, right, bottom, then left padding.'));
     $post_types = array($this->id);
     $type_metapanel_settings = array('id' => 'banner-metapanel', 'name' => "Banner Setup Options", 'posttype' => $post_types, 'hide_tabs' => true);
     $type_meta_panel = new PageLinesMetaPanel($type_metapanel_settings);
     $type_metatab_settings = array('id' => 'banner-type-metatab', 'name' => "Banner Setup Options", 'icon' => $this->icon);
     $type_meta_panel->register_tab($type_metatab_settings, $type_meta_array);
     $metatab_array = array('banner_set' => array('version' => 'pro', 'type' => 'select_taxonomy', 'taxonomy_id' => "banner-sets", 'title' => 'Select Banner Set To Show', 'desc' => 'If you are using the Banner section, select the banner set you would like to show on this page.'), 'banner_items' => array('version' => 'pro', 'type' => 'text', 'size' => 'small', 'title' => 'Max Number of Banners', 'desc' => 'Enter the max number of banners to show on this page. If left blank, the number of posts selected under settings > "reading" will be used.'));
     $metatab_settings = array('id' => 'banner_page_meta', 'name' => "Banner Section", 'icon' => $this->icon);
     register_metatab($metatab_settings, $metatab_array);
 }
 function section_persistent()
 {
     /* 
     	Create Custom Post Type 
     */
     $args = array('label' => __('Features', 'pagelines'), 'singular_label' => __('Feature', 'pagelines'), 'description' => 'For setting slides on the feature page template', 'taxonomies' => array('feature-sets'));
     $taxonomies = array('feature-sets' => array("label" => __('Feature Sets', 'pagelines'), "singular_label" => __('Feature Set', 'pagelines')));
     $columns = array("cb" => "<input type=\"checkbox\" />", "title" => "Title", "feature-description" => "Text", "feature-media" => "Media", "feature-sets" => "Feature Sets");
     $column_value_function = 'feature_column_display';
     $this->post_type = new PageLinesPostType($this->id, $args, $taxonomies, $columns, $column_value_function);
     /* Set default posts if none are present */
     $this->post_type->set_default_posts('pagelines_default_features');
     /*
     	Create meta fields for the post type
     */
     $type_meta_array = array('feature-style' => array('type' => 'select', 'title' => 'Feature Text Position', 'desc' => 'Select the type of feature style you would like to be shown. E.g. show text on left, right, bottom or not at all (full width)...', 'selectvalues' => array('text-left' => 'Text On Left', 'text-right' => 'Text On Right', 'text-bottom' => 'Text On Bottom', 'text-none' => 'Full Width Image or Media - No Text')), 'feature-background-image' => array('desc' => 'Upload an image for the feature background.', 'title' => 'Feature Background Image', 'type' => 'image_upload'), 'feature-design' => array('type' => 'select', 'desc' => 'Select the design style you would like this feature to have (e.g. default background color, text color, overlay? etc...).', 'title' => 'Feature Design Style', 'selectvalues' => array('fstyle-darkbg-overlay' => 'White Text - Dark Feature Background - Transparent Text Overlay (Default)', 'fstyle-lightbg' => 'Black Text - Light Feature Background with Border - No Overlay', 'fstyle-darkbg' => 'White Text - Dark Feature Background - No Overlay', 'fstyle-nobg' => 'Black Text - No Feature Background - No Overlay')), 'feature-media-image' => array('version' => 'pro', 'type' => 'image_upload', 'title' => 'Feature Media Image', 'label' => 'Upload An Image For The Feature Media Area', 'desc' => 'Upload an image of the appropriate size for the feature media area.'), 'feature-media' => array('version' => 'pro', 'type' => 'textarea', 'title' => 'Feature Media HTML (Youtube, Flash etc...)', 'label' => 'Enter HTML For Feature Media Area', 'desc' => 'Feature Page Media HTML or Embed Code.'), 'feature-thumb' => array('desc' => 'Add thumbnails to your post for use in thumb navigation. Create an image 50px wide by 30px tall and upload here.', 'title' => 'Feature Thumb (50px by 30px)', 'label' => 'Upload Feature Thumbnail (Thumbs Mode)', 'type' => 'image_upload'), 'feature-link-url' => array('desc' => 'Adding a URL here will add a link to your feature slide', 'title' => 'Feature Link URL', 'label' => 'Enter Feature Link URL', 'type' => 'text'), 'feature-link-text' => array('default' => 'More', 'desc' => 'Enter the text you would like in your feature link', 'title' => 'Link Text', 'label' => 'Enter Feature Link Text', 'type' => 'text', 'size' => 'small'), 'feature-name' => array('default' => '', 'desc' => 'Enter the title you would like to appear when the feature nav mode is set to feature names', 'title' => 'Navigation Label', 'label' => 'Enter Feature Navigation Text (Names Nav Mode)', 'type' => 'text'));
     // Add options for correct post type.
     $post_types = pagelines('feature_source') == 'posts' ? array($this->id, 'post') : array($this->id);
     $type_metapanel_settings = array('id' => 'feature-metapanel', 'name' => "Feature Setup Options", 'posttype' => $post_types, 'hide_tabs' => true);
     $type_meta_panel = new PageLinesMetaPanel($type_metapanel_settings);
     $type_metatab_settings = array('id' => 'feature-type-metatab', 'name' => "Feature Setup Options", 'icon' => $this->icon);
     $type_meta_panel->register_tab($type_metatab_settings, $type_meta_array);
     /*
     	Do Page/Post Options
     */
     $page_metatab_array = array('feature_items' => array('version' => 'pro', 'type' => 'text', 'size' => 'small', 'title' => 'Number of Feature Slides', 'desc' => 'Enter the max number of feature slides to show on this page. Note: If left blank, the number of posts selected under reading settings in the admin will be used.'), 'feature_set' => array('version' => 'pro', 'type' => 'select_taxonomy', 'taxonomy_id' => "feature-sets", 'title' => 'Select Feature Set To Show', 'desc' => 'If you are using the feature section, select the feature set you would like to show on this page.'));
     $metatab_settings = array('id' => 'feature_meta', 'name' => "Feature Slider Section", 'icon' => $this->icon);
     register_metatab($metatab_settings, $page_metatab_array);
 }
예제 #4
0
 /**
  *
  * @TODO document
  *
  */
 function post_meta_setup()
 {
     $type_meta_array = array('box_setup' => array('type' => 'multi_option', 'title' => __('Individual Box Options', 'pagelines'), 'shortexp' => __('Basic setup options for handling of this box', 'pagelines'), 'selectvalues' => array('the_box_icon' => array('type' => 'image_upload', 'inputlabel' => __('Box Image', 'pagelines')), 'the_box_icon_link' => array('type' => 'text', 'inputlabel' => __('Box Link (Optional)', 'pagelines')), 'the_box_icon_target' => array('type' => 'check', 'inputlabel' => __('Open link in New Window?', 'pagelines')), 'box_class' => array('default' => '', 'type' => 'text', 'size' => 'small', 'inputlabel' => __('Boxes Custom Class', 'pagelines')), 'box_more_text' => array('default' => '', 'type' => 'text', 'size' => 'small', 'inputlabel' => __('More Link Text (Shows if link and text is set)', 'pagelines')))));
     $post_types = array($this->id);
     $type_metapanel_settings = array('id' => 'boxes-metapanel', 'name' => PL_THEMENAME . ' Box Options', 'posttype' => $post_types);
     global $boxes_meta_panel;
     $boxes_meta_panel = new PageLinesMetaPanel($type_metapanel_settings);
     $type_metatab_settings = array('id' => 'boxes-type-metatab', 'name' => 'Box Setup Options', 'icon' => $this->icon);
     $boxes_meta_panel->register_tab($type_metatab_settings, $type_meta_array);
 }
예제 #5
0
 /**
  *
  * @TODO document
  *
  */
 function type_meta_options()
 {
     /* Meta Options */
     $type_meta_array = array('banner_align' => array('version' => 'pro', 'type' => 'select', 'selectvalues' => array('banner_right' => array('name' => __('Banner Right', 'pagelines')), 'banner_left' => array('name' => __('Banner Left', 'pagelines'))), 'title' => __('Banner Alignment', 'pagelines'), 'shortexp' => __('Put the media on the right or the left?', 'pagelines')), 'the_banner_image' => array('type' => 'image_upload', 'title' => __('Banner Media', 'pagelines'), 'shortexp' => __('Upload an image for the banner.', 'pagelines')), 'banner_text_width' => array('type' => 'count_select', 'count_start' => '1', 'count_number' => '100', 'title' => __('Banner Text Width (In %)', 'pagelines'), 'shortexp' => __('Set the width of the text area as a percentage of full content width.  The media area will fill the rest.', 'pagelines')), 'the_banner_media' => array('type' => 'textarea', 'title' => __('Banner Media', 'pagelines'), 'shortexp' => __('Add HTML Media for the banner, e.g. Youtube embed code. This option is used if there is no image uploaded.', 'pagelines')), 'banner_text_padding' => array('version' => 'pro', 'type' => 'text', 'size' => 'small', 'title' => __('Banner Text Padding', 'pagelines'), 'shortexp' => __('Configure the padding and arrangement of banner text', 'pagelines'), 'exp' => __('(optional) Set the padding for the text area. Use CSS shorthand, for example:<strong> 25px 30px 25px 35px</strong> for top, right, bottom, then left padding.<br/><br/><strong>Heads Up</strong> If you do not set this option, the banner will attempt to vertically align the text for you.', 'pagelines')));
     $post_types = array($this->id);
     $type_metapanel_settings = array('id' => 'banner-metapanel', 'name' => __('Banner Setup Options', 'pagelines'), 'posttype' => $post_types, 'hide_tabs' => true);
     $type_meta_panel = new PageLinesMetaPanel($type_metapanel_settings);
     $type_metatab_settings = array('id' => 'banner-type-metatab', 'name' => __('Banner Setup Options', 'pagelines'), 'icon' => $this->icon);
     $type_meta_panel->register_tab($type_metatab_settings, $type_meta_array);
 }
예제 #6
0
 /**
  *
  * @TODO document
  *
  */
 function post_meta_setup()
 {
     $pt_tab_options = array('feature_styling' => array('type' => 'multi_option', 'title' => __('Feature Design Style', 'pagelines'), 'shortexp' => __('The basic styling of the feature', 'pagelines'), 'selectvalues' => array('feature-style' => array('type' => 'select', 'inputlabel' => __('Feature Text Position', 'pagelines'), 'selectvalues' => array('text-left' => array('name' => __('Text On Left', 'pagelines')), 'text-right' => array('name' => __('Text On Right', 'pagelines')), 'text-bottom' => array('name' => __('Text On Bottom', 'pagelines')), 'text-none' => array('name' => __('Full Width Background Image - No Text - Links Entire BG', 'pagelines')))), 'feature-design' => array('type' => 'select', 'inputlabel' => __('Feature Design Style', 'pagelines'), 'selectvalues' => array('fstyle-darkbg-overlay' => array('name' => __('White Text - Dark Feature Background - Transparent Text Overlay (Default)', 'pagelines')), 'fstyle-lightbg' => array('name' => __('Black Text - Light Feature Background with Border - No Overlay', 'pagelines')), 'fstyle-darkbg' => array('name' => __('White Text - Dark Feature Background - No Overlay', 'pagelines')), 'fstyle-nobg' => array('name' => __('Black Text - No Feature Background - No Overlay', 'pagelines')))))), 'feature_media_stuff' => array('type' => 'multi_option', 'title' => __('Feature Media', 'pagelines'), 'shortexp' => __('The media that the feature will use', 'pagelines'), 'selectvalues' => array('feature-background-image' => array('inputlabel' => __('Full Size - Feature Background Image', 'pagelines'), 'type' => 'image_upload'), 'feature-media-image' => array('version' => 'pro', 'type' => 'image_upload', 'inputlabel' => __('Media Area - Image (optional)', 'pagelines')), 'feature-media' => array('version' => 'pro', 'type' => 'textarea', 'inputlabel' => __('Feature HTML (video embeds etc, In Media Area)', 'pagelines')), 'feature-media-full' => array('version' => 'pro', 'type' => 'check', 'inputlabel' => __('Make Feature HTML Full Width', 'pagelines')), 'feature-thumb' => array('inputlabel' => __('Thumb Navigation - Upload Feature Thumbnail (50px by 30px)', 'pagelines'), 'type' => 'image_upload'), 'feature-name' => array('default' => '', 'inputlabel' => __('Names Navigation - Enter Text', 'pagelines'), 'type' => 'text'))), 'feature-link-url' => array('shortexp' => __('Adding a URL here will add a link to your feature slide', 'pagelines'), 'title' => __('Feature Link URL', 'pagelines'), 'label' => __('Enter Feature Link URL', 'pagelines'), 'type' => 'text', 'exp' => __('Adds a More link to your text. If you have Full Width Background Image mode selected, the entire slide will be linked.', 'pagelines')), 'feature-link-text' => array('default' => 'More', 'shortexp' => __('Enter the text you would like in your feature link', 'pagelines'), 'title' => __('Link Text', 'pagelines'), 'label' => __('Enter Feature Link Text', 'pagelines'), 'type' => 'text', 'size' => 'small'));
     $posts_mode = ploption('posts_feature_control') ? true : false;
     // Add options for correct post type.
     $post_types = $posts_mode ? array($this->ptID, 'post') : array($this->ptID);
     $pt_panel = array('id' => 'feature-metapanel', 'name' => __('Feature Setup Options', 'pagelines'), 'posttype' => $post_types, 'hide_tabs' => true);
     $pt_panel = new PageLinesMetaPanel($pt_panel);
     $pt_tab = array('id' => 'feature-type-metatab', 'name' => __('Feature Setup Options', 'pagelines'), 'icon' => $this->icon);
     $pt_panel->register_tab($pt_tab, $pt_tab_options);
 }