本文整理汇总了PHP中RevSliderFunctions::getHtmlLink方法的典型用法代码示例。如果您正苦于以下问题:PHP RevSliderFunctions::getHtmlLink方法的具体用法?PHP RevSliderFunctions::getHtmlLink怎么用?PHP RevSliderFunctions::getHtmlLink使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类RevSliderFunctions
的用法示例。
在下文中一共展示了RevSliderFunctions::getHtmlLink方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: stripslashes
}
$imageFilepath = $slide->getImageFilepath();
$urlImageForView = $slide->getThumbUrl();
$slideTitle = $slide->getParam("title", "Slide");
$title = $slideTitle;
$filename = $slide->getImageFilename();
$imageAlt = stripslashes($slideTitle);
if (empty($imageAlt)) {
$imageAlt = "slide";
}
if ($bgType == "image") {
$title .= " (" . $filename . ")";
}
$slideid = $slide->getID();
$urlEditSlide = self::getViewUrl(RevSliderAdmin::VIEW_SLIDE, "id={$slideid}");
$linkEdit = RevSliderFunctions::getHtmlLink($urlEditSlide, $title);
$state = $slide->getParam("state", "published");
?>
<li id="slidelist_item_<?php
echo $slideid;
?>
" class="ui-state-default">
<span class="slide-col col-order">
<span class="order-text"><?php
echo $counter;
?>
</span>
<div class="state_loader" style="display:none;"></div>
<?php
if ($state == "published") {
示例2: importSliderTemplateHandle
/**
*
* import slider handle (not ajax response)
*/
private static function importSliderTemplateHandle($viewBack = null, $updateAnim = true, $updateStatic = true, $single_slide = false)
{
dmp(__("importing template slider settings and data...", 'revslider'));
$uid = esc_attr(RevSliderFunctions::getPostVariable('uid'));
if ($uid == '') {
dmp(__("ID missing, something went wrong. Please try again!", 'revslider'));
echo RevSliderFunctions::getHtmlLink($viewBack, __("Go Back", 'revslider'));
exit;
}
//check if the filename is correct
//import to templates, then duplicate Slider
$slider = new RevSlider();
$response = $slider->importSliderFromPost($updateAnim, $updateStatic, false, $uid, $single_slide);
if ($single_slide === false) {
if (empty($viewBack)) {
$sliderID = $response["sliderID"];
$viewBack = self::getViewUrl(self::VIEW_SLIDER, "id=" . $sliderID);
if (empty($sliderID)) {
$viewBack = self::getViewUrl(self::VIEW_SLIDERS);
}
}
}
//handle error
if ($response["success"] == false) {
$message = $response["error"];
dmp("<b>Error: " . $message . "</b>");
echo RevSliderFunctions::getHtmlLink($viewBack, __("Go Back", 'revslider'));
} else {
//handle success, js redirect.
dmp(__("Slider Import Success, redirecting...", 'revslider'));
echo "<script>location.href='{$viewBack}'</script>";
}
exit;
}
示例3: catch
if (intval($numSlides) == 0) {
$first_slide_id = 'new&slider=' . $id;
} else {
$slides = $slider->getSlides(false);
if (!empty($slides)) {
$first_slide_id = $slides[key($slides)]->getID();
//$first_slide_id = ($isFromPosts == true) ? $slides[key($slides)]->templateID : $slides[key($slides)]->getID();
$first_slide_image_thumb = $slides[key($slides)]->get_image_attributes($slider_type);
} else {
$first_slide_id = 'new&slider=' . $id;
}
}
$editLink = self::getViewUrl(RevSliderAdmin::VIEW_SLIDER, "id={$id}");
$orderSlidesLink = $isFromPosts ? self::getViewUrl(RevSliderAdmin::VIEW_SLIDES, "id={$id}") : '';
$editSlidesLink = self::getViewUrl(RevSliderAdmin::VIEW_SLIDE, "id={$first_slide_id}");
$showTitle = RevSliderFunctions::getHtmlLink($editLink, $showTitle);
} catch (Exception $e) {
$errorMessage = "ERROR: " . $e->getMessage();
$strSource = "";
$numSlides = "";
$isFromPosts = false;
}
?>
<li class="tls-slide tls-stype-all tls-stype-<?php
echo $slider_type;
?>
" data-favorit="<?php
echo $is_favorite ? 'a' : 'b';
?>
" data-id="<?php
echo $id;