只在帖子内显示广告
Code:
<?php
$rand_posts = get_posts('numberposts=10&orderby=rand');
foreach( $rand_posts as $post ) :
if (($wp_query->current_post == 0)and (!is_home())) : ?>
<div style="float:right"><br>
ad here
</div>
<?php endif; $postcnt++; ?>
效果:
http://www.wordpublish.org/msjq.htm