本文整理汇总了PHP中virtue_excerpt函数的典型用法代码示例。如果您正苦于以下问题:PHP virtue_excerpt函数的具体用法?PHP virtue_excerpt怎么用?PHP virtue_excerpt使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了virtue_excerpt函数的8个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: the_title
" class="bcarousellink">
<header>
<h5 class="entry-title" itemprop="name headline"><?php
the_title();
?>
</h5>
<div class="subhead" itemprop="datePublished">
<span class="postday"><?php
echo get_the_date(get_option('date_format'));
?>
</span>
</div>
</header>
<div class="entry-content" itemprop="articleBody">
<p><?php
echo virtue_excerpt(16);
?>
</p>
</div>
</a>
</div>
</div>
<?php
}
} else {
?>
<div class="error-not-found"><?php
_e('Sorry, no blog entries found.', 'virtue');
?>
</div>
<?php
示例2: kad_portfolio_shortcode_function
//.........这里部分代码省略.........
the_permalink();
?>
" title="<?php
the_title();
?>
">
<img src="<?php
echo esc_url($image);
?>
" alt="<?php
the_title();
?>
" class="lightboxhover" style="display: block;">
</a>
</div>
<?php
if (!empty($lightbox)) {
?>
<a href="<?php
echo esc_url($thumbnailURL);
?>
" class="kad_portfolio_lightbox_link" title="<?php
the_title();
?>
" data-rel="lightbox">
<i class="icon-search"></i>
</a>
<?php
}
$image = null;
$thumbnailURL = null;
?>
<?php
}
}
?>
<a href="<?php
the_permalink();
?>
" class="portfoliolink">
<div class="piteminfo">
<h5><?php
the_title();
?>
</h5>
<?php
if (empty($showtypes)) {
$terms = get_the_terms($post->ID, 'portfolio-type');
if ($terms) {
?>
<p class="cportfoliotag"><?php
$output = array();
foreach ($terms as $term) {
$output[] = $term->name;
}
echo implode(', ', $output);
?>
</p>
<?php
}
}
?>
<?php
if ($excerpt == true) {
?>
<p><?php
echo virtue_excerpt(16);
?>
</p>
<?php
}
?>
</div>
</a>
</div>
</div>
<?php
}
} else {
?>
<li class="error-not-found"><?php
_e('Sorry, no portfolio entries found.', 'virtue');
?>
</li>
<?php
}
?>
</div> <!-- portfoliowrapper -->
<?php
$wp_query = null;
wp_reset_query();
?>
</div><!-- /.home-portfolio -->
<?php
$output = ob_get_contents();
ob_end_clean();
return $output;
}
示例3: the_title
" class="bcarousellink">
<header>
<h5 class="entry-title" itemprop="name headline"><?php
the_title();
?>
</h5>
<div class="subhead" itemprop="datePublished">
<span class="postday"><?php
echo get_the_date(get_option('date_format'));
?>
</span>
</div>
</header>
<div class="entry-content" itemprop="articleBody">
<p><?php
echo strip_tags(virtue_excerpt(16));
?>
</p>
</div>
</a>
</div>
</div>
<?php
}
} else {
?>
<div class="error-not-found"><?php
_e('Sorry, no blog entries found.', 'virtue');
?>
</div>
<?php
示例4: kad_carousel_shortcode_function
//.........这里部分代码省略.........
$thumbnailURL = null;
}
}
?>
<a href="<?php
the_permalink();
?>
" class="portfoliolink">
<div class="piteminfo">
<h5><?php
the_title();
?>
</h5>
<?php
if ($portfolio_show_types == true) {
$terms = get_the_terms($post->ID, 'portfolio-type');
if ($terms) {
?>
<p class="cportfoliotag"><?php
$output = array();
foreach ($terms as $term) {
$output[] = $term->name;
}
echo implode(', ', $output);
?>
</p> <?php
}
}
?>
<?php
if ($portfolio_show_excerpt == true) {
?>
<p><?php
echo virtue_excerpt(16);
?>
</p> <?php
}
?>
</div>
</a>
</div>
</div>
<?php
}
} else {
?>
<li class="error-not-found"><?php
_e('Sorry, no portfolio entries found.', 'virtue');
?>
</li>
<?php
}
$wp_query = null;
wp_reset_query();
?>
<?php
} else {
if ($type == "post") {
$wp_query = null;
$wp_query = new WP_Query();
$wp_query->query(array('orderby' => $orderby, 'order' => $order, 'offset' => $offset, 'post_type' => 'post', 'category_name' => $carousel_category, 'posts_per_page' => $items));
if ($wp_query) {
while ($wp_query->have_posts()) {
$wp_query->the_post();
?>
示例5: get_comments_number
<span class="kad-hidepostedin">|</span>
<span class="postcommentscount" rel="tooltip" data-placement="top" data-original-title="<?php
$num_comments = get_comments_number();
echo esc_attr($num_comments);
?>
">
<i class="icon-bubbles"></i>
</span>
<?php
}
?>
</div>
</header>
<div class="entry-content" itemprop="articleBody">
<p><?php
echo virtue_excerpt($blogwordcount);
?>
<a href="<?php
the_permalink();
?>
">
<?php
global $virtue_premium;
if (!empty($virtue_premium['post_readmore_text'])) {
$readmore = $virtue_premium['post_readmore_text'];
} else {
$readmore = __('Read More', 'virtue');
}
echo $readmore;
?>
</a></p>
示例6: kad_carousel_shortcode_function
//.........这里部分代码省略.........
?>
">
<img src="<?php
echo $image;
?>
" alt="<?php
the_title();
?>
" class="iconhover" style="display:block;">
</a>
</div>
<?php
$image = null;
$thumbnailURL = null;
?>
<a href="<?php
the_permalink();
?>
" class="bcarousellink">
<header>
<h5 class="entry-title"><?php
the_title();
?>
</h5>
<div class="subhead">
<span class="postday kad-hidedate"><?php
echo get_the_date('j M Y');
?>
</span>
</div>
</header>
<div class="entry-content color_body">
<p><?php
echo strip_tags(virtue_excerpt(16));
if ($readmore) {
global $virtue_premium;
if (!empty($virtue_premium['post_readmore_text'])) {
$readmoret = $virtue_premium['post_readmore_text'];
} else {
$readmoret = __('Read More', 'virtue');
}
echo $readmoret;
}
?>
</p>
</div>
</a>
</div>
</div>
<?php
}
} else {
?>
<div class="error-not-found"><?php
_e('Sorry, no post entries found.', 'virtue');
?>
</div>
<?php
}
$wp_query = null;
wp_reset_query();
?>
</div>
</div>
<?php
示例7: get_comments_number
<span class="kad-hidepostedin">|</span>
<span class="postcommentscount" data-toggle="tooltip" data-placement="top" data-original-title="<?php
$num_comments = get_comments_number();
echo esc_attr($num_comments);
?>
">
<i class="icon-comments-alt"></i>
</span>
<?php
}
?>
</div>
</header>
<div class="entry-content">
<p><?php
echo virtue_excerpt(34);
?>
<a href="<?php
the_permalink();
?>
"><?php
_e('READ MORE', 'virtue');
?>
</a></p>
</div>
<footer>
</footer>
</div>
</div>
</article>
</div>
示例8: kad_blog_shortcode_function
//.........这里部分代码省略.........
</div>
</div>
<header class="home_blog_title">
<a href="<?php
the_permalink();
?>
"><h5 class="entry-title"><?php
the_title();
?>
</h5></a>
<div class="subhead color_gray">
<span class="postauthortop" rel="tooltip" data-placement="top" data-original-title="<?php
echo get_the_author();
?>
">
<i class="icon-user"></i>
</span>
<span class="kad-hidepostauthortop"> | </span>
<?php
$post_category = get_the_category($post->ID);
if (!empty($post_category)) {
?>
<span class="postedintop" rel="tooltip" data-placement="top" data-original-title="<?php
foreach ($post_category as $category) {
echo $category->name . ' ';
}
?>
"><i class="icon-folder"></i></span>
<?php
}
?>
<?php
if (comments_open() || get_comments_number() != 0) {
?>
<span class="kad-hidepostedin">|</span>
<span class="postcommentscount" rel="tooltip" data-placement="top" data-original-title="<?php
esc_attr(get_comments_number());
?>
">
<i class="icon-bubbles"></i>
</span>
<?php
}
?>
</div>
</header>
<div class="entry-content">
<p><?php
echo virtue_excerpt($word_count);
?>
<a href="<?php
the_permalink();
?>
">
<?php
global $virtue_premium;
if (!empty($virtue_premium['post_readmore_text'])) {
$readmore = $virtue_premium['post_readmore_text'];
} else {
$readmore = __('Read More', 'virtue');
}
echo $readmore;
?>
</a></p>
</div>
<footer>
</footer>
</div>
</div>
</article>
</div>
<?php
}
} else {
?>
<li class="error-not-found"><?php
_e('Sorry, no blog entries found.', 'virtue');
?>
</li>
<?php
}
?>
<?php
$wp_query = null;
wp_reset_query();
?>
</div>
</div> <!--home-blog -->
<?php
$output = ob_get_contents();
ob_end_clean();
return $output;
}
}