本文整理汇总了PHP中yt_placehold函数的典型用法代码示例。如果您正苦于以下问题:PHP yt_placehold函数的具体用法?PHP yt_placehold怎么用?PHP yt_placehold使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了yt_placehold函数的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的PHP代码示例。
示例1: yt_placehold
<?php
if ($options->item_image_display == 1) {
?>
<div class="bsn-image">
<a href="<?php
echo $items->image;
?>
" title="" data-rel="prettyPhoto">
<?php
//Create placeholder images
$src = $items->image;
if (file_exists($src)) {
echo "<img src='" . Ytools::resize($items->image, $image_config) . "' alt='" . $items->title . "'/>";
} else {
if ($is_placehold) {
echo yt_placehold($placehold_size['featured_posts']);
}
}
?>
</a>
</div>
<?php
}
?>
<h2>
<a title="<?php
echo $items->title;
?>
" target="<?php
echo $options->item_link_target;
开发者ID:electronixcraft,项目名称:qs,代码行数:31,代码来源:default.php
示例2: empty
$imgfloat = empty($images->float_intro) ? $params->get('float_intro') : $images->float_intro;
?>
<?php
// Begin: The way to resize your image.
$templateParams = JFactory::getApplication()->getTemplate(true)->params;
YTTemplateUtils::getImageResizerHelper(array('background' => $templateParams->get('thumbnail_background', '#000'), 'thumbnail_mode' => $templateParams->get('thumbnail_mode', 'fit')));
$imgW = isset($leadingFlag) && $leadingFlag ? $templateParams->get('leading_width', '300') : $templateParams->get('intro_width', '200');
$imgH = isset($leadingFlag) && $leadingFlag ? $templateParams->get('leading_height', '300') : $templateParams->get('intro_height', '200');
$imgsrc = YTTemplateUtils::resize($images->image_intro, $imgW, $imgH);
//Create placeholder items images
$src = $images->image_intro;
if (file_exists(JPATH_BASE . '/' . $src)) {
$thumb_img = '<img src="' . $imgsrc . '" alt="' . $images->image_intro_alt . '" />';
} else {
if ($is_placehold) {
$thumb_img = yt_placehold($placehold_size['leading']);
}
}
?>
<figure class="pull-<?php
echo htmlspecialchars($imgfloat);
?>
item-image" >
<a class="listingimg" title="<?php
echo htmlspecialchars($images->image_fulltext_alt);
?>
" href="<?php
echo JRoute::_(ContentHelperRoute::getArticleRoute($this->item->slug, $this->item->catid));
?>
" >
<?php
开发者ID:rodhoff,项目名称:MNW,代码行数:31,代码来源:default_leading.php
示例3: empty
if ($this->params->get('tag_list_show_item_image', 1) == 1 && !empty($images->image_intro)) {
?>
<?php
$imgfloat = empty($images->float_intro) ? 'left' : $images->float_intro;
//$imgfloat = (empty($images->float_fulltext)) ? 'none' :$images->float_fulltext;
$imgW = isset($leadingFlag) && $leadingFlag ? $templateParams->get('leading_width', '870') : $templateParams->get('intro_width', '200');
$imgH = isset($leadingFlag) && $leadingFlag ? $templateParams->get('leading_height', '320') : $templateParams->get('intro_height', '200');
$imgsrc = YTTemplateUtils::resize($images->image_intro, $imgW, $imgH, array($templateParams->get('thumbnail_background', '#ffffff')));
//Create placeholder items images
$src = $images->image_intro;
if (file_exists(JPATH_BASE . '/' . $src)) {
$thumb_img = '<img src="' . $src . '" alt="' . $images->image_intro_alt . '" />';
$full_img = JURI::base() . '/' . htmlspecialchars($images->image_intro);
} else {
if ($is_placehold) {
$thumb_img = yt_placehold($placehold_size['article']);
$full_img = 'http://placehold.it/' . $placehold_size['article'] . '/969696';
}
}
?>
<figure class="pull-<?php
echo htmlspecialchars($imgfloat);
?>
item-image" >
<?php
echo $thumb_img;
?>
</figure>
<?php
}
开发者ID:educacionbe,项目名称:stabwall,代码行数:31,代码来源:default_items.php
示例4: yt_placehold
?>
" title="<?php
echo JText::_('K2_CONTINUE_READING');
?>
"<?php
echo K2HelperUtilities::cleanHtml($item->title);
?>
"">
<?php
//Create placeholder items images
$src = $item->image;
if (!empty($src)) {
$thumb_img = '<img src="' . $src . '" alt="' . $item->title . '" />';
} else {
if ($is_placehold) {
$thumb_img = yt_placehold($placehold_size['k2contentReviews'], $item->title, $item->title);
}
}
echo $thumb_img;
?>
</a>
<?php
}
?>
<?php
if ($params->get('itemCommentsCounter')) {
?>
开发者ID:rodhoff,项目名称:MNW,代码行数:31,代码来源:default.php
示例5: yt_placehold
" target="<?php
echo $options->item_link_target;
?>
" href="<?php
echo $items->link;
?>
">
<?php
//Create placeholder images
$src = $items->image;
if (file_exists($src)) {
echo "<img src='" . Ytools::resize($items->image, $image_config) . "' alt='" . $items->title . "'/>";
} else {
if ($is_placehold) {
echo yt_placehold($placehold_size['popular']);
}
}
?>
</a>
</div>
<?php
}
?>
<h2 class="basicnews-title">
<a title="<?php
echo $items->title;
?>
" target="<?php
echo $options->item_link_target;
开发者ID:electronixcraft,项目名称:qs,代码行数:31,代码来源:tabs.php
示例6: isset
if (!empty($this->item->image_caption)) {
echo K2HelperUtilities::cleanHtml($this->item->image_caption);
} else {
echo K2HelperUtilities::cleanHtml($this->item->title);
}
?>
">
<?php
//Create placeholder items images
$src = isset($this->item->image) ? $this->item->image : '';
if (!empty($src)) {
$thumb_img = '<img src="' . $src . '" alt="' . $item->title . '" />';
} else {
if ($is_placehold) {
$thumb_img = yt_placehold($placehold_size['listing'], $this->item->title, $this->item->title);
}
}
echo $thumb_img;
?>
</a>
</div>
<?php
}
?>
<div class="catItemHeader">
<?php
if ($this->item->params->get('latestItemTitle')) {
?>
开发者ID:rodhoff,项目名称:MNW,代码行数:31,代码来源:latest_item.php
示例7: yt_placehold
echo JText::_('K2_CONTINUE_READING');
?>
"<?php
echo K2HelperUtilities::cleanHtml($item->title);
?>
"">
<?php
//Create placeholder items images
if (isset($item->image)) {
$src = $item->image;
}
if (!empty($src)) {
$thumb_img = '<img src="' . $src . '" alt="' . K2HelperUtilities::cleanHtml($item->title) . '" />';
} else {
if ($is_placehold) {
$thumb_img = yt_placehold($placehold_size['k2_content_featured'], $item->title, $item->title);
}
}
echo $thumb_img;
?>
</a>
<?php
}
?>
<?php
}
?>
开发者ID:rodhoff,项目名称:MNW,代码行数:30,代码来源:default.php
示例8: yt_placehold
?>
" target="<?php
echo $options->item_link_target;
?>
" href="<?php
echo $items->link;
?>
">
<?php
//Create placeholder images
$src = $items->image;
if (file_exists($src)) {
echo "<img src='" . Ytools::resize($items->image, $image_config) . "' alt='" . $items->title . "'/>";
} else {
if ($is_placehold) {
echo yt_placehold($placehold_size['video_box']);
}
}
?>
</a>
</div>
<?php
}
?>
<?php
开发者ID:educakanchay,项目名称:educared,代码行数:31,代码来源:video.php
示例9: yt_placehold
if ($commenter->userImage) {
?>
<a class="k2Avatar tcAvatar" rel="author" href="<?php
echo $commenter->link;
?>
">
<?php
if (isset($commenter->userImage)) {
$src = $commenter->userImage;
}
if (!empty($src)) {
$thumb_img = '<img style="width:' . $tcAvatarWidth . 'px;height:auto;" src="' . $src . '" alt="' . JFilterOutput::cleanText($commenter->userName) . '" />';
} else {
if ($is_placehold) {
$thumb_img = yt_placehold($placehold_size['k2_content_avatar'], $commenter->userName, $commenter->userName);
}
}
echo $thumb_img;
?>
</a>
<?php
}
?>
<?php
if ($params->get('commenterLink')) {
?>
<a class="tcLink" rel="author" href="<?php
echo $commenter->link;
?>
开发者ID:rodhoff,项目名称:MNW,代码行数:31,代码来源:commenters.php
示例10: yt_placehold
echo JText::_('K2_CONTINUE_READING');
?>
"<?php
echo K2HelperUtilities::cleanHtml($item->title);
?>
"">
<?php
//Create placeholder items images
if (isset($item->image)) {
$src = $item->image;
}
if (!empty($src)) {
$thumb_img = '<img src="' . $src . '" alt="' . $item->title . '" />';
} else {
if ($is_placehold) {
$thumb_img = yt_placehold($placehold_size['small'], $item->title, $item->title);
//var_dump( $thumb_img);
}
}
echo $thumb_img;
?>
</a>
<?php
}
?>
<div class="main">
<?php
if ($params->get('itemTitle')) {
?>
<a class="moduleItemTitle" href="<?php
echo $item->link;
开发者ID:educakanchay,项目名称:educared,代码行数:31,代码来源:default.php
示例11: isset
?>
<?php
// Begin: The way to resize your image.
$templateParams = JFactory::getApplication()->getTemplate(true)->params;
YTTemplateUtils::getImageResizerHelper(array('background' => $templateParams->get('thumbnail_background', '#000'), 'thumbnail_mode' => $templateParams->get('thumbnail_mode', 'fit')));
$imgW = isset($leadingFlag) && $leadingFlag ? $templateParams->get('leading_width', '300') : $templateParams->get('intro_width', '200');
$imgH = isset($leadingFlag) && $leadingFlag ? $templateParams->get('leading_height', '300') : $templateParams->get('intro_height', '200');
//$imgsrc = YTTemplateUtils::resize($images->image_intro, $imgW, $imgH);
$imgsrc = $images->image_intro;
//Create placeholder items images
$src = $images->image_intro;
if (file_exists(JPATH_BASE . '/' . $src) || strpos($src, 'http://') !== false) {
$thumb_img = '<img width="60" src="' . $imgsrc . '" alt="' . $images->image_intro_alt . '" />';
} else {
if ($is_placehold) {
$thumb_img = yt_placehold($placehold_size['small']);
}
}
?>
<figure class="pull-<?php
echo htmlspecialchars($imgfloat);
?>
item-image" >
<?php
echo $thumb_img;
?>
</figure>
<?php
}
开发者ID:educacionbe,项目名称:stabwall,代码行数:31,代码来源:tabs_image.php
示例12: yt_placehold
echo JText::_('K2_CONTINUE_READING');
?>
"<?php
echo K2HelperUtilities::cleanHtml($item->title);
?>
"">
<?php
//Create placeholder items images
if (isset($item->image)) {
$src = $item->image;
}
if (!empty($src)) {
$thumb_img = '<img src="' . $src . '" alt="' . $item->title . '" />';
} else {
if ($is_placehold) {
$thumb_img = yt_placehold($placehold_size['latest_news'], $item->title, $item->title);
//var_dump( $thumb_img);
}
}
echo $thumb_img;
?>
</a>
<?php
if ($params->get('itemReadMore') && $item->fulltext) {
?>
<a class="moduleItemReadMore" href="<?php
echo $item->link;
?>
">
<?php
echo JText::_('K2_VIEW_MORE');
开发者ID:educakanchay,项目名称:kanchay,代码行数:31,代码来源:default.php
示例13: yt_placehold
<div class="images-slideshow">
<img alt="<?php
echo $item->displaytitle;
?>
" src="<?php
echo $img;
?>
"/>
</div>
<?php
} else {
$no_image = ' no-images';
echo yt_placehold($placehold_size['slideshow']);
}
?>
<div class="item-content">
<div class="item-content-inner">
<?php
// display title
if ($item->displaytitle != '') {
?>
<h3 class="item-title">
<a href="<?php
echo $item->link;
?>
" title="<?php
开发者ID:educakanchay,项目名称:educa,代码行数:30,代码来源:default.php
示例14: yt_placehold
?>
" target="<?php
echo $options->item_link_target;
?>
" href="<?php
echo $items->link;
?>
">
<?php
//Create placeholder images
$src = $items->image;
if (file_exists($src)) {
echo "<img src='" . Ytools::resize($items->image, $image_config) . "' alt='" . $items->title . "'/>";
} else {
if ($is_placehold) {
echo yt_placehold($placehold_size['latest_news']);
}
}
?>
</a>
<a class="hover-link" href="<?php
echo $items->link;
?>
" target="<?php
echo $options->item_link_target;
?>
">
</a>
</div>
<?php
开发者ID:electronixcraft,项目名称:qs,代码行数:31,代码来源:latestnews.php
示例15: yt_placehold
<?php
if ((int) $this->params->get('item_image_display', 1)) {
?>
<div class="img-fulltext pull-none">
<?php
$img = BaseHelper::getArticleImage($item, $_params);
//Create placeholder images
if (isset($img['src'])) {
$src = $img['src'];
}
if (file_exists($src)) {
echo BaseHelper::imageTag($img);
} else {
if ($is_placehold) {
echo yt_placehold($placehold_size['related_items']);
}
}
?>
</div>
<?php
}
?>
<?php
if ((int) $_params->get('item_date_display', 1) == 1) {
?>
<span class="related-item-date"><?php
echo JHtml::date($item->created, 'd.m.Y');
?>
开发者ID:educacionbe,项目名称:stabwall,代码行数:31,代码来源:default.php
示例16: yt_placehold
<a class="" data-rel="prettyPhoto" href="<?php
echo $this->item->imageXLarge;
?>
" title="<?php
echo JText::_('K2_CLICK_TO_PREVIEW_IMAGE');
?>
">
<?php
//Create placeholder items images
$src = $this->item->image;
if (!empty($src)) {
$thumb_img = '<img src="' . $src . '" alt="' . $this->item->title . '" />';
} else {
if ($is_placehold) {
$thumb_img = yt_placehold($placehold_size['article'], $this->item->title);
}
}
echo $thumb_img;
?>
</a>
</div>
<?php
if ($this->item->params->get('itemImageMainCaption') && !empty($this->item->image_caption)) {
?>
<!-- Image caption -->
<span class="itemImageCaption"><?php
echo $this->item->image_caption;
?>
开发者ID:proyectoseb,项目名称:University,代码行数:30,代码来源:item.php
示例17: foreach
<ul class="items">
<?php
foreach ($this->relatedItems as $key => $item) {
?>
<li class="item">
<div class="item-images">
<?php
$src_rela = $item->imageLarge;
$title_rela = K2HelperUtilities::cleanHtml($item->title);
if ($this->item->params->get('itemRelatedImageSize')) {
//Create placeholder items images
if (!empty($src_rela)) {
$thumb_img = '<img src="' . $src_rela . '" alt="' . $title_rela . '" />';
} else {
if ($is_placehold) {
$thumb_img = yt_placehold($placehold_size['related_items'], $this->item->title);
}
}
echo $thumb_img;
}
?>
</div>
<?php
if ($this->item->params->get('itemRelatedTitle', 1)) {
?>
<h3 class="itemRelTitle" ><a href="<?php
echo $item->link;
?>
"><?php
echo $item->title;
?>
开发者ID:educakanchay,项目名称:educared,代码行数:31,代码来源:item.php
示例18: yt_placehold
>
<?php
//Create placeholder images
if (isset($img)) {
?>
<img alt="<?php
echo $item->displaytitle;
?>
" src="<?php
echo $img;
?>
"/>
<?php
} else {
echo yt_placehold($placehold_size['slider']);
}
?>
</a>
<a data-rel="prettyPhoto" href="<?php
echo $img;
?>
" title="<?php
echo $item->title;
?>
" class="item-image">
<i class="fa fa-plus"></i>
</a>
</div>
</div>
<?php
开发者ID:educakanchay,项目名称:educared,代码行数:31,代码来源:our-team.php
示例19: isset
?>
<?php
// Begin: The way to resize your image.
$templateParams = JFactory::getApplication()->getTemplate(true)->params;
YTTemplateUtils::getImageResizerHelper(array('background' => $templateParams->get('thumbnail_background', '#000'), 'thumbnail_mode' => $templateParams->get('thumbnail_mode', 'fit')));
$imgW = isset($leadingFlag) && $leadingFlag ? $templateParams->get('leading_width', '300') : $templateParams->get('intro_width', '200');
$imgH = isset($leadingFlag) && $leadingFlag ? $templateParams->get('leading_height', '300') : $templateParams->get('intro_height', '200');
$imgsrc = YTTemplateUtils::resize($images->image_intro, $imgW, $imgH);
//Create placeholder items images
$src = $images->image_intro;
if (file_exists(JPATH_BASE . '/' . $src)) {
$thumb_img = '<img src="' . $imgsrc . '" alt="' . $images->image_intro_alt . '" />';
$full_img = JURI::base() . '/' . htmlspecialchars($images->image_intro);
} else {
if ($is_placehold) {
$thumb_img = yt_placehold($placehold_size['listing']);
$full_img = 'http://placehold.it/' . $placehold_size['article'] . '/969696';
}
}
?>
<figure class="pull-<?php
echo htmlspecialchars($imgfloat);
?>
item-image" >
<a data-rel="prettyPhoto" title="<?php
echo htmlspecialchars($images->image_fulltext_alt);
?>
" href="<?php
echo $full_img;
?>
" >
开发者ID:electronixcraft,项目名称:qs,代码行数:31,代码来源:default_item.php
示例20: isset
?>
<?php
// Begin: The way to resize your image.
$templateParams = JFactory::getApplication()->getTemplate(true)->params;
YTTemplateUtils::getImageResizerHelper(array('background' => $templateParams->get('thumbnail_background', '#000'), 'thumbnail_mode' => $templateParams->get('thumbnail_mode', 'fit')));
$imgW = isset($leadingFlag) && $leadingFlag ? $templateParams->get('leading_width', '300') : $templateParams->get('intro_width', '200');
$imgH = isset($leadingFlag) && $leadingFlag ? $templateParams->get('leading_height', '300') : $templateParams->get('intro_height', '200');
//$imgsrc = YTTemplateUtils::resize($images->image_intro, $imgW, $imgH);
$imgsrc = $images->image_intro;
//Create placeholder items images
$src = $images->image_intro;
if (file_exists(JPATH_BASE . '/' . $src) || strpos($src, 'http://') !== false) {
$thumb_img = '<img src="' . $imgsrc . '" alt="' . $images->image_intro_alt . '" />';
} else {
if ($is_placehold) {
$thumb_img = yt_placehold($placehold_size['project']);
}
}
?>
<figure class="pull-<?php
echo htmlspecialchars($imgfloat);
?>
item-image" >
<?php
echo $thumb_img;
?>
</figure>
<?php
}
开发者ID:educacionbe,项目名称:stabwall,代码行数:31,代码来源:project_image.php
注:本文中的yt_placehold函数示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论