写法1:
$fr=$empire->fetch1(\"select infotags from {$dbtbpre}ecms_news_data_{$r
写法1:
$fr=$empire->fetch1("select infotags from {$dbtbpre}ecms_news_data_{$r[stb]} where id='$r[id]'");
$infotags=$fr['infotags'];
$r_tag=explode(",",$infotags);
$tagstr=dp_InfoTag($r['classid'],$r['id'],'| ',5);
for($i=0;$i<count($r_tag);$i ){
if($r_tag[$i]){
$tagslink=$public_r[newsurl]."e/tags/?tagname=".urlencode($r_tag[$i]);
$tags.="<a href='$tagslink' target='_blank' rel='tag'>".$r_tag[$i]."</a>";
}
}
$cl=$empire->fetch1("select classname from {$dbtbpre}enewsclass where classid='$r[classid]'");
$classname=$cl['classname'];
if($r['titlepic']!=''){
$titlepic='<a href="[!--titleurl--]" rel="external nofollow" rel="external nofollow" rel="external nofollow" rel="external nofollow" rel="external nofollow" rel="external nofollow" class="pic"> <img class="lazy" src="[!--titlepic--]" alt="[!--oldtitle--]" title="[!--oldtitle--]" width="200" height="150"> </a>';
}else{
$titlepic='<a href="[!--titleurl--]" rel="external nofollow" rel="external nofollow" rel="external nofollow" rel="external nofollow" rel="external nofollow" rel="external nofollow" class="pic"> <img class="lazy" src="[!--news.url--]skin/ecms249/images/notimg.gif" alt="[!--oldtitle--]" title="[!--oldtitle--]" width="200" height="150"> </a>';
}
$listtemp='<li class="post_part clear"> '.$titlepic.'
<div class="cont">
<h3><a href="[!--titleurl--]" rel="external nofollow" rel="external nofollow" rel="external nofollow" rel="external nofollow" rel="external nofollow" rel="external nofollow" class="title">[!--title--]</a></h3>
<div class="info"> <span class="author"> <a href="[!--this.classlink--]" rel="external nofollow" class="name">'.$classname.'</a> <span class="gap_point">•</span><span>[!--newstime--]</span> </span> </div>
<p class="summary">[!--smalltext--]... </p>
<div class="tag"> <i class="fa fa-tag"></i> '.$tagstr.' </div>
</div>
</li>';
写法2:
$fr=$empire->fetch1("select infotags from {$dbtbpre}ecms_news_data_{$r[stb]} where id='$r[id]'");
$infotags=$fr['infotags'];
$r_tag=explode(",",$infotags);
for($i=0;$i<count($r_tag);$i ){
if($r_tag[$i]){
$tagslink=$public_r[newsurl]."e/tags/?tagname=".urlencode($r_tag[$i]);
$tags.="<a href='$tagslink' target='_blank' rel='tag'>".$r_tag[$i]."</a>";
}
}
$cl=$empire->fetch1("select classname from {$dbtbpre}enewsclass where classid='$r[classid]'");
$classname=$cl['classname'];
if($r['titlepic']!=''){
$titlepic='
<li class="ls_list_li ts">
<div class="li_l fl photo yj_10">
<a href="[!--titleurl--]" rel="external nofollow" rel="external nofollow" rel="external nofollow" rel="external nofollow" rel="external nofollow" rel="external nofollow" class="l_img" target="_blank" title="[!--oldtitle--]"><img src="[!--titlepic--]" alt="[!--oldtitle--]"></a>
</div>
<div class="li_r fr">
<h3><a href="[!--titleurl--]" rel="external nofollow" rel="external nofollow" rel="external nofollow" rel="external nofollow" rel="external nofollow" rel="external nofollow" class="f18 bt_a nobold chao" target="_blank" title="[!--oldtitle--]">'.DoTitleFont($r[titlefont],$r[title]).'</a></h3>
<p class="chao2 c9 f13 bj_mt15">[!--smalltext--]...</p>
<div class="div_b bj_mt15">
<time class="c9 f12"><em class="cc f12">时间:</em>[!--newstime--]</time>
</div>
</div>
</li>
';
}else{
$titlepic='
<li class="ls_list_li list_li ts">
<div class="li_r">
<h3><a href="[!--titleurl--]" rel="external nofollow" rel="external nofollow" rel="external nofollow" rel="external nofollow" rel="external nofollow" rel="external nofollow" class="f18 bt_a chao nobold" target="_blank" title="[!--oldtitle--]">'.DoTitleFont($r[titlefont],$r[title]).'</a></h3>
<p class="chao2 c9 f13 bj_mt15">[!--smalltext--]...</p>
<div class="div_b bj_mt15">
<time class="c9 f12"><em class="cc f12">时间:</em>[!--newstime--]</time>
</div>
</div>
</li>
';
}
$listtemp='
'.$titlepic.'
';
声明:
1.本站大部分内容均收集于网络!若内容若侵犯到您的权益,请发送邮件至:115904045@qq.com,我们将第一时间处理!
2.资源所需价格并非资源售卖价格,是收集、整理、编辑详情以及本站运营的适当补贴,并且本站不提供任何免费技术支持
3.所有资源仅限于参考和学习,版权归原作者所有,更多请阅读网站声明。
1.本站大部分内容均收集于网络!若内容若侵犯到您的权益,请发送邮件至:115904045@qq.com,我们将第一时间处理!
2.资源所需价格并非资源售卖价格,是收集、整理、编辑详情以及本站运营的适当补贴,并且本站不提供任何免费技术支持
3.所有资源仅限于参考和学习,版权归原作者所有,更多请阅读网站声明。