原创 2018-05-08 12:50 热度: 5 评论 0 条【推荐给百度】
这是针对当前博客主题在首页里面所修改后的滚动公告代码;
由原来固定的公告内容变为整站最新文章的调用;
具体代码如下:
- <!--首页滚动公告开始-->
- <nav class="breadcrumb">
- <div id="scrolldiv">
- <div class="bull"></div>
- <div class="scrolltext">
- <ul style="margin-top: 0px;">
- <?php
- $scrollcount = get_option('ygj_new_post');
- ?>
- <?php
- query_posts('&showposts='.$scrollcount.'&ignore_sticky_posts=1.&cat='.get_option('ygj_new_exclude'));
- while ( have_posts ) : the_post;$do_not_duplicate = $post->ID; ?>
- <li class="scrolltext-title"><a href="<?php%20the_permalink;%20?>" target="_blank"><?php the_title; ?></a>
- </li>
- <?php endwhile; ?>
- </ul>
- </div>
- </div>
- <script type="text/javascript">$(document).ready(function {$("#scrolldiv").textSlider({line: 1, speed: 1000,
- timer: 3000});})</script>
- </nav>
- <!--首页滚动公告结束-->
付涛的微信扫一扫/加好友/聊一聊
微信机器人高级版扫一扫看效果【免费下载】
文章导航
- 我的微信
- 这是我的微信扫一扫
- 我的微信公众号
- 我的微信公众号扫一扫