当前位置: 首页>>代码示例>>PHP>>正文


PHP related_posts函数代码示例

本文整理汇总了PHP中related_posts函数的典型用法代码示例。如果您正苦于以下问题:PHP related_posts函数的具体用法?PHP related_posts怎么用?PHP related_posts使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。


在下文中一共展示了related_posts函数的13个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: related_posts_sidebar_module

function related_posts_sidebar_module($args)
{
    extract($args);
    if (is_single() and !defined('K2_NOT_FOUND')) {
        echo $before_module . $before_title . $title . $after_title;
        ?>
			<ul>
				<?php 
        related_posts();
        ?>
			</ul>
		<?php 
        echo $after_module;
    }
}
开发者ID:64kbytes,项目名称:stayinba,代码行数:15,代码来源:related_posts.php

示例2: wp_link_pages

			<div class="ps-pagination">
				<?php 
        wp_link_pages(array('before' => '<ul class="pagination ps-pages"><a>Pages</a>', 'after' => '</ul>', 'link_before' => '<span>', 'link_after' => '</span>'));
        ?>
 
			</div>

			<?php 
        if (function_exists('related_posts') || ot_get_option('pst_content_below') != '') {
            ?>
	<div id="belowpst-stuff" class="well well-default well-sm">
		<div class="relatedpst col-md-6">
		<?php 
            if (function_exists('related_posts')) {
                related_posts();
            }
            ?>
		</div>
		<?php 
            if (ot_get_option('pst_content_below') != '') {
                ?>
 
		<div class="pst-ad-below col-md-6"><?php 
                echo ot_get_option('pst_content_below');
                ?>
</div>
		<?php 
            }
            ?>
<div class="fix"></div>
开发者ID:supersonique-studio,项目名称:BlueStrap,代码行数:30,代码来源:single.php

示例3: the_modified_date

        the_modified_date();
        ?>
</span>
                        </div>

                        <div class="dataBlock">
							<h2>Tags</h2>
							<div id="tagList">
								<?php 
        the_tags(__('', 'html5blank'), '', '<br>');
        ?>
							</div>

						</div><div class="dataBlock">
							<?php 
        related_posts($post);
        ?>
						</div>


						<?php 
        list_references("ref");
        ?>



                    </div><!-- /post -->



开发者ID:Whitevinyl,项目名称:BLOKDUST_GUIDE,代码行数:27,代码来源:single.php

示例4: relatedposts

function relatedposts()
{
    /* echo '<div id = "relatedposts" style = "background: #f9f9f9; padding: 24px;">'; */
    related_posts();
    /*echo '</div>'; */
}
开发者ID:ashenkar,项目名称:sanga,代码行数:6,代码来源:single.php

示例5: author_box

        if (rd_options('reedwan_post_author') == 1) {
            ?>
				<div class="box-author mts clearfix">	
					<?php 
            echo author_box(get_the_author_meta('ID'), true);
            ?>
		
				</div>
				<?php 
        }
        ?>
				<?php 
        if (rd_options('reedwan_post_similar') == 1) {
            ?>
					<?php 
            echo related_posts(rd_options('reedwan_post_similar_number'), rd_options('reedwan_post_similar_by'), get_the_ID());
            ?>
				<?php 
        }
        ?>
				<?php 
        if ($post_comment != 'comment_none') {
            ?>
				<div class="single-comments mts clearfix">
					<?php 
            if ($post_comment == 'comment_disqus') {
                ?>
						<?php 
                echo disqus_embed($disqus_shortname);
                ?>
					<?php 
开发者ID:devmoonshine,项目名称:development,代码行数:31,代码来源:single.php

示例6: array



			<!--<div class="block-top-b wrapper <?php 
    if ($this['config']->get('block-top-b')) {
        echo 'max-width' . $this['config']->get('block-top-b');
    }
    ?>
"> -->

					<!--<section id="top-b"><?php 
    echo $this['modules']->render('top-b', array('layout' => $this['config']->get('top-b')));
    ?>
</section>-->

				<?php 
    echo $this->render('social_icons');
    ?>
				<div style="clear:both"></div><hr/>
				<?php 
    related_posts('main');
    ?>

		<!--</div> -->


		</div>
		<?php 
}
?>

	</div>
开发者ID:navetisyan,项目名称:asatryans,代码行数:29,代码来源:main.php

示例7: hybrid_related_posts

/**
* Shows related posts by plugin
* Only show if plugin is active
*
* @since 0.2.2
*
* @plugin - http://wasabi.pbwiki.com/Related%20Entries
* @plugin - http://rmarsh.com/plugins/similar-posts
* @plugin - http://wordpress.org/extend/plugins/wordpress-23-related-posts-plugin
***********************************************************/
function hybrid_related_posts()
{
    if (function_exists('related_posts') || function_exists('similar_posts') || function_exists('wp_related_posts')) {
        echo '<div class="related-posts">';
        echo '<h3>' . __('Related Posts', 'options') . '</h3>';
        if (function_exists('related_posts')) {
            echo '<ul class="related">';
            related_posts();
            echo '</ul>';
        } elseif (function_exists('similar_posts')) {
            similar_posts();
        } elseif (function_exists('wp_related_posts')) {
            wp_related_posts();
        }
        echo '</div>';
    }
}
开发者ID:alicam,项目名称:vanilla-theme,代码行数:27,代码来源:template-functions.php

示例8: the_author_meta

            }
            ?>
                </div>
                <div class="hentry-author-about"><?php 
            the_author_meta('description');
            ?>
</div>
            </div>
            <?php 
        }
        ?>

            <?php 
        if (get_option('unspoken_rel_type2')) {
            if (function_exists('related_posts')) {
                related_posts(array('template_file' => 'yarpp-template-similar.php'));
            }
        }
        ?>

            <?php 
        if (get_option('unspoken_share_type1')) {
            ?>
            <div class="hentry-widget hentry-share">
                <h6><?php 
            _e('Share this article', 'unspoken');
            ?>
</h6>
                <ul>
                    
                    <li class="twitter"><a href="http://twitter.com/share?text=<?php 
开发者ID:bidhanbaral,项目名称:fotodep_store,代码行数:31,代码来源:loop-single.php

示例9: blog_posts

<?php

include 'header.php';
$blog_posts = blog_posts();
$related = related_posts();
?>

<?php 
############################################
$deps = depoimentos();
$depsdados = $deps['array'];
$depscount = $deps['contador'];
############################################
?>

<div id="aparelhos">
	<div id="aparelhos-titulo-pagina">
		<p class="Oswald fs-38 azul fw700">blog</p>
	</div>
	<div class="aparelhos-content">
		<?php 
foreach ($blog_posts as $posts) {
    ?>
			<article>
				<h2 class="Oswald fs-24 fw400 azul mt0"><?php 
    echo $posts['titulo'];
    ?>
</h2>
				<!-- h3 class="Cycle fs-16 fw400"><?php 
    echo BDtoBR($posts['datacad']);
    ?>
开发者ID:mvnp,项目名称:purophp,代码行数:31,代码来源:blog-post.php

示例10: azexo_post_nav

    if (isset($options['post_navigation']) && $options['post_navigation'] == 'before') {
        azexo_post_nav();
    }
    ?>
                <?php 
    get_template_part('content', get_post_format());
    ?>
                
                <?php 
    if (isset($options['post_navigation']) && $options['post_navigation'] == 'after') {
        azexo_post_nav();
    }
    ?>
                <?php 
    if (function_exists('related_posts')) {
        related_posts(array('template' => 'yarpp-template-default.php'));
    }
    ?>
                <?php 
    if (comments_open()) {
        comments_template();
    }
    ?>

            <?php 
}
?>

        </div><!-- #content -->
    </div><!-- #primary -->
开发者ID:mauricioabisay,项目名称:loc,代码行数:30,代码来源:single.php

示例11: or_related_posts_fn

function or_related_posts_fn()
{
    if (function_exists('related_posts')) {
        echo "<h3>" . __('Related Posts:') . "</h3>\n";
        echo "<ul>\n";
        related_posts();
        echo "</ul>\n";
    }
}
开发者ID:jonkemp,项目名称:outrigger,代码行数:9,代码来源:functions.php

示例12: widget

 function widget($args, $instance)
 {
     extract($args, EXTR_SKIP);
     echo $before_widget;
     $title = empty($instance['title']) ? '&nbsp;' : apply_filters('widget_title', $instance['title']);
     if (!empty($title)) {
         echo $before_title . $title . $after_title;
     }
     if (!function_exists('related_posts') || !related_posts()) {
     }
     echo $after_widget;
 }
开发者ID:enetter,项目名称:ecores,代码行数:12,代码来源:ecs_widgets.php

示例13: wp_reset_query

    <?php 
    if (!is_single()) {
        ?>
        <section class="related">
        <?php 
        wp_reset_query();
        $args = array('posts_per_page' => 1, 'orderby' => 'comment_count', 'order' => 'DESC', 'ignore_sticky_posts' => 1);
        $popular_posts = new WP_Query($args);
        remove_filter('posts_where', 'filter_where');
        if ($popular_posts->have_posts()) {
            while ($popular_posts->have_posts()) {
                $popular_posts->the_post();
                ?>
		    <div class="clearfix"></div>
		    <?php 
                related_posts(array('template_file' => 'yarpp-template-t5-simple.php'), true, get_the_ID());
                ?>
			<?php 
            }
        }
        ?>
		</section>
    </div>
    <div class="clearfix"></div>
    <?php 
    }
    ?>
    
</section>

<?php 
开发者ID:digideskio,项目名称:Travelllll,代码行数:31,代码来源:trending.php


注:本文中的related_posts函数示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。