//----------------------- //select item template $templates = new ShowBizTemplate(); $arrTemplates = $templates->getArrShortAssoc(GlobalsShowBiz::TEMPLATE_TYPE_ITEM, true); $params = array("description" => "The template that set the look of the item (if not selected it will be taken from the slider global template)"); $slideSettings->addSelect("template_id", $arrTemplates, "Item Template", "", $params); $slideSettings->addHr(); //----------------------- //enable link $slideSettings->addSelect_boolean("enable_link", "Enable Link", false, "Enable", "Disable"); $slideSettings->startBulkControl("enable_link", UniteSettingsBiz::CONTROL_TYPE_SHOW, "true"); //link $params = array("description" => "A link on the whole slide pic"); $slideSettings->addTextBox("link", "", "Slide Link", $params); $slideSettings->addHr(); $slideSettings->endBulkControl(); $params = array("description" => "", "width" => 300, "height" => 200); $slideSettings->addImage("slide_image", "", "Slide Image", $params); //editor $params = array("description" => ""); $slideSettings->addEditor("slide_text", "", "Slide Text", $params); $params = array("description" => "Overwrite the global excerpt words limit option for this slide", "class" => "small"); $slideSettings->addTextBox("showbiz_excerpt_limit", "", "Excerpt Words Limit", $params); $slideSettings->addHr(); $params = array("description" => "The youtube ID, example: 9bZkp7q19f0", "class" => "medium"); $slideSettings->addTextBox("youtube_id", "", "Youtube ID", $params); $params = array("description" => "The youtube ID, example: 18554749", "class" => "medium"); $slideSettings->addTextBox("vimeo_id", "", "Vimeo ID", $params); $slideSettings->addHr(); //add the wildcards $slideSettings->addStaticText("Those custom options can be used for variety of purposes in the templates section.");
$arrPostTypes = UniteFunctionsWPBiz::getPostTypesAssoc(); $arrParams = array("args" => "multiple size='5'"); $sliderMainSettings->addSelect("post_types", $arrPostTypes, "Post Types", "post", $arrParams); //post categories $arrParams = array("args" => "multiple size='7'"); $sliderMainSettings->addSelect("post_category", array(), "Post Categories", "", $arrParams); //sort by $arrSortBy = UniteFunctionsWPBiz::getArrSortBy(); $sliderMainSettings->addSelect("post_sortby", $arrSortBy, "Sort Posts By", ShowBizSlider::DEFAULT_POST_SORTBY); //sort direction $arrSortDir = UniteFunctionsWPBiz::getArrSortDirection(); $sliderMainSettings->addRadio("posts_sort_direction", $arrSortDir, "Sort Direction", ShowBizSlider::DEFAULT_POST_SORTDIR); //max posts for slider $arrParams = array("class" => "small", "unit" => "posts"); $sliderMainSettings->addTextBox("max_slider_posts", "30", "Max Posts Per Slider", $arrParams); $sliderMainSettings->endBulkControl(); $sliderMainSettings->startBulkControl("source_type", UniteSettingsBiz::CONTROL_TYPE_SHOW, "gallery"); $sliderMainSettings->addRadio("img_random_order", array("on" => "On", "off" => "Off"), "Random Order", 'off'); $sliderMainSettings->endBulkControl(); // -------------- Specific IDs ------------------ $arrParams = array("description" => "Type here the post IDs you want to use separated by coma. ex: 23,24,25"); $sliderMainSettings->addTextBox("posts_list", "", "Specific Posts List", $arrParams); $sliderMainSettings->addControl("source_type", "posts_list", UniteSettingsBiz::CONTROL_TYPE_SHOW, "specific_posts"); $arrParams = array("class" => "small", "unit" => "words/characters"); $sliderMainSettings->addTextBox("title_limit", "99", "Limit The Title To", $arrParams); $arrParams = array("class" => "small", "unit" => "words/characters"); $sliderMainSettings->addTextBox("excerpt_limit", "55", "Limit The Excerpt To", $arrParams); $arrLimitTypes = array("words" => "Words", "character" => "Characters"); $sliderMainSettings->addSelect("limit_by_type", $arrLimitTypes, "Limit By", "words"); //$arrParams = array("class"=>"normal","description"=>"Specifies the delimiter where word ends to limit title/excerpt. Default is a space."); //$sliderMainSettings->addTextBox("word_end", " ", "Delimiter Char", $arrParams);