缓存时间需要到对应的模版中修改的
以blog_index.html.php为例
- <?exit?>
- {template blog_header}
- <!-- 第一版块 -->
- <div class="contentleftbg">
- <div class="colleft">
- <div id="picblog">
- <h3>图文日志</h3>
- <SCRIPT type=text/javascript>
- <!--
- var focus_width=165;
- var focus_height=150;
- var text_height=0;
- //-->
- </SCRIPT>
- <!--图片BLOG(图片+标题) begin--><!--{block name="spaceblog" parameter="haveattach/1/showattach/1/order/i.dateline DESC/limit/0,4/cachetime/3600/tpl/item_subject_pic"}--><!--图片BLOG(图片+标题) end-->
- </div>
- <div id="recentcomment">
- <h3>最新评论</h3>
- <ul>
- <!--最新评论列表 begin--><!--{block name="spacecomment" parameter="order/dateline DESC/limit/0,16/subjectlen/20/cachetime/1800/tpl/item_subject_list"}--><!--最新评论列表 end-->
- </ul>
- </div>
- </div>
- <div class="colmid">
- <div id="recent">
- <div class="title">
- <h3>最新发表BLOG</h3>
- <a href="#action/itemlist/type/blog/order/dateline#" class="more">MORE</a>
- </div>
- <ul>
- <!--最新spaceBLOG列表 begin--><!--{block name="spaceblog" parameter="showspacename/1/order/i.dateline DESC/limit/0,21/cachetime/900/subjectlen/40/tpl/item_subject_spacename"}--><!--最新spaceBLOG列表 end-->
- </ul>
- </div>
- </div>
- <div class="colright">
- <div id="userpanel">$div[userpanel]</div>
- <div id="blogstar">
- <h3>个人空间之星</h3>
- <div>
- <!--用户X-space博客之星 begin--><!--{block name="userspace" parameter="isstar/1/showdetail/1/order/u.dateline DESC/limit/0,1/cachetime/43200/tpl/space_photo_name_list"}--><!--用户X-space博客之星 end-->
- </div>
- </div>
- <div id="tags">
- <h3>热门TAGs</h3>
- <ul>
- <!--热点TAG名列表 begin--><!--{block name="tag" parameter="order/spaceblognum DESC/limit/0,25/cachetime/86400/tpl/tag_tagname_list"}--><!--热点TAG名列表 end-->
- </ul>
- </div>
- </div>
- <div class="hackbox"></div>
- </div>
- <!-- 第一版块结束 -->
- <div class="banner760">
- <!-- 页面中部大横幅 START--><iframe src="{S_URL}/batch.ad.php?id=2" name="_ad_2" width="760" height="70" marginwidth="0" frameborder="0" scrolling="no"></iframe><!-- 页面中部大横幅 END-->
- </div>
- <div class="contentleftbg">
- <div class="colleft">
- <div id="hotarticle">
- <h3>热门BLOG</h3>
- <ul>
- <!--热点SpaceBLOG列表 begin--><!--{block name="spaceblog" parameter="order/i.viewnum DESC/limit/0,10/cachetime/7200/subjectlen/22/tpl/item_subject_list"}--><!--热点SpaceBLOG列表 end-->
- </ul>
- </div>
- <div id="hotcomment">
- <h3>回复最多的BLOG</h3>
- <ul>
- <!--热点SpaceBLOG列表 begin--><!--{block name="spaceblog" parameter="order/i.replynum DESC/limit/0,10/cachetime/7225/subjectlen/22/tpl/item_subject_list"}--><!--热点SpaceBLOG列表 end-->
- </ul>
- </div>
- <div id="good">
- <h3>好评最多的BLOG</h3>
- <ul>
- <!--热点SpaceBLOG列表 begin--><!--{block name="spaceblog" parameter="order/i.goodrate DESC/limit/0,10/cachetime/7250/subjectlen/22/tpl/item_subject_list"}--><!--热点SpaceBLOG列表 end-->
- </ul>
- </div>
- <div class="banner120">
- <!-- 页面左栏小广告(120*60) START--><iframe src="{S_URL}/batch.ad.php?id=3" name="_ad_3" width="120" height="60" marginwidth="0" frameborder="0" scrolling="no"></iframe><!-- 页面左栏小广告(120*60) END-->
- </div>
- </div>
- <div class="colmid">
-
- <!--{loop $_SBLOCK[category] $ckey $cat}-->
- <div class="blogcate">
- <div class="title">
- <h3>$cat[name]</h3>
- <a href="#action/category/catid/$cat[catid]#" class="more">MORE</a>
- </div>
- <ul>
- {eval $ctime=900+5*$ckey;}
- <!--BLOG最新列表 begin--><!--{block name="spaceblog" parameter="catid/$cat[catid]/showspacename/1/order/i.dateline DESC/limit/0,5/cachetime/$ctime/subjectlen/28/tpl/item_subject_spacename"}--><!--BLOG最新列表 end-->
- </ul>
- </div>
- <!--{/loop}-->
- </div>
- <div class="colright">
- <div>
- <h3>热门个人空间</h3>
- <ul>
- <!--space列表 begin--><!--{block name="userspace" parameter="order/u.spaceblognum DESC/limit/0,10/cachetime/43200/tpl/space_name_list"}--><!--space列表 end-->
- </ul>
- </div>
- <div id="newblog">
- <h3>最新个人空间</h3>
- <ul>
- <!--space列表 begin--><!--{block name="userspace" parameter="order/u.dateline DESC/limit/0,10/cachetime/43200/tpl/space_name_list"}--><!--space列表 end-->
- </ul>
- </div>
- <div id="newpost">
- <h3>最近更新个人空间</h3>
- <ul>
- <!--space列表 begin--><!--{block name="userspace" parameter="order/u.lastpost DESC/limit/0,10/cachetime/43200/tpl/space_name_list"}--><!--space列表 end-->
- </ul>
- </div>
- <div class="banner120">
- <!-- 页面右栏小广告(120*60) START--><iframe src="{S_URL}/batch.ad.php?id=4" name="_ad_4" width="120" height="60" marginwidth="0" frameborder="0" scrolling="no"></iframe><!-- 页面右栏小广告(120*60) END-->
- </div>
- </div>
- <div class="hackbox"></div>
- </div>
- </div>
- {template blog_footer}
复制代码
cachetime/这个后面的数字都是相应各项的缓存时间,以s计算 |