K9调用显示最早被百度搜索引擎收录过的内容标签用法:
{@res.join table1='%s_content_botdate' table2='%s_content' field2='id,title,url,description,comment,iscomment,date'on='id' where="t2.status=1" order='t1.date' number='30'} {#foreach($res as $rs)} <h2><a href="{DIR}{$rs[url]}">{$rs[title]}</a></h2> <p>{$rs[description]}</p> <div> <a href="{DIR}{$rs[url]}" class="more">查看全文</a> {#if($rs['iscomment'])} - <a href="{DIR}?content-comment&id={$rs[id]}&pid=1" class="comments">评论({$rs[comment]})</a> {#endif} <em>{$rs[date] date='Y-m-d'}</em> </div> {#endforeach}说明:
数据表king_content_botdate:记录爬虫访问的时间,可以根据这个调出随机优化爬虫访问,具体的作用您懂的。
转载请注明出处:唯众网络