本文整理匯總了PHP中RevSliderOutput::getSlider方法的典型用法代碼示例。如果您正苦於以下問題:PHP RevSliderOutput::getSlider方法的具體用法?PHP RevSliderOutput::getSlider怎麽用?PHP RevSliderOutput::getSlider使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類RevSliderOutput
的用法示例。
在下文中一共展示了RevSliderOutput::getSlider方法的4個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。
示例1: putSlider
/**
*
* put the kb slider slider on the html page.
* @param $data - mixed, can be ID ot Alias.
*/
public static function putSlider($sliderID, $putIn = "")
{
if (strtolower($putIn) == "homepage" && is_front_page() == false) {
return false;
}
$output = new RevSliderOutput();
$output->putSliderBase($sliderID);
$slider = $output->getSlider();
return $slider;
}
示例2: putSlider
/**
*
* put the rev slider slider on the html page.
* @param $data - mixed, can be ID ot Alias.
*/
public static function putSlider($sliderID, $putIn = "")
{
$isPutIn = self::isPutIn($putIn);
if ($isPutIn == false) {
return false;
}
$output = new RevSliderOutput();
$output->putSliderBase($sliderID);
$slider = $output->getSlider();
return $slider;
}
示例3: putSlider
/**
*
* put the kb slider slider on the html page.
* @param $data - mixed, can be ID ot Alias.
*/
public static function putSlider($sliderID, $putIn = "")
{
$putIn = strtolower($putIn);
if ($putIn == "homepage") {
//filter by homepage
if (is_front_page() == false) {
return false;
}
} else {
//case filter by pages
if (!empty($putIn)) {
$arrPutInPages = array();
$arrPagesTemp = explode(",", $putIn);
foreach ($arrPagesTemp as $page) {
if (is_numeric($page) || $page == "homepage") {
$arrPutInPages[] = $page;
}
}
if (!empty($arrPutInPages)) {
//get current page id
$currentPageID = "";
if (is_front_page() == true) {
$currentPageID = "homepage";
} else {
global $post;
if (isset($post->ID)) {
$currentPageID = $post->ID;
}
}
//do the filter by pages
if (array_search($currentPageID, $arrPutInPages) === false) {
return false;
}
}
}
}
$output = new RevSliderOutput();
$output->putSliderBase($sliderID);
$slider = $output->getSlider();
return $slider;
}
示例4: putSlider
/**
* put the rev slider slider on the html page.
* @param $data - mixed, can be ID ot Alias.
*/
public static function putSlider($sliderID, $putIn = "", $gal_ids = array(), $settings = array(), $order = array())
{
$settings = apply_filters('revslider_modify_slider_settings', $settings, $sliderID);
$isPutIn = self::isPutIn($putIn);
if ($isPutIn == false) {
return false;
}
//check if on mobile and if option hide on mobile is set
$output = new RevSliderOutput();
$output->putSliderBase($sliderID, $gal_ids, false, $settings, $order);
$slider = $output->getSlider();
return $slider;
}