
帝國CMS在內容模板里控制內容簡介smalltext顯示字數
帝國CMS的內容簡介通常都是自動截取200個字符的。但有時我們希望在內容模板中不需要顯示這么多,只要顯示幾十個字,那么可以使用以下代碼截取顯示:<?=esub($navinfor[smalltext],字數)?>...
帝國CMS的內容簡介通常都是自動截取200個字符的。但有時我們希望在內容模板中不需要顯示這么多,只要顯示幾十個字,那么可以使用以下代碼截取顯示:<?=esub($navinfor[smalltext],字數)?>...
在用帝國CMS做網站的時候,為了美化網頁,我們常常需要根據不同的字段值用不同的圖片來代替,比如商品中的顏色,我們希望用顏色圖片來代替各種顏色顯示。又如下圖:00.jpg有兩個字段值:“新家教、緊急”。通常我們用...
update phome_ecms_download set titleurl=replace(titleurl,'http://www.daixiao360.cn','http://127.0.0.1');update phome_ecms_download set titlepic=replace(titlepic,'http://www.daixiao360.cn','http://127....
列表內容模板(list.var)代碼:$uid=$empire->fetch1("select * from {$dbtbpre}enewsmemberadd where userid={$r[userid]}");$usql=$empire->fetch1("select * from {$dbtbpre}enewsmember where userid = {$r['userid...
帝國默認TXT格式的文件是不可以下載,不修改源文件他會直接打開方法TXT彈出下載:測試版本:帝國CMS7.0功能位置:后臺->其他管理->下載模型管理->管理地址前綴相關函數:e/class/DownSysFun.php DoTypeForDownurl() , QDownLoa...
<?$sql=$empire->query("select id,title from {$dbtbpre}ecms_news where id>5000 order by id limit 1000");while($r=$empire->fetch($sql)){if($r[title]){$zm=GetInfoZm($r[title]);$empire->query("update {$db...
內容頁:<?=DoTitleFont($navinfor[titlefont],$navinfor[title])?>靈動標簽:<?=DoTitleFont($bqr[titlefont],$bqr[title])?>標題截取字數+標題屬性:<?=DoTitleFont($bqr[titlefont],esub($bqr[title],32,'...'))?>...
php三元條件運算符:<?=$bqr['ftitle']?$bqr['ftitle']:$bqr['title']?>靈動或者php查詢調用編輯器內容的時候要加stripslashes刪除反斜杠比如:<?=stripslashes($r['newstext'])?>內容頁當前信息ID:$navinfor['id']列表內...
<?php$class_sql=$empire->fetch1('select classid,classname,bname from '.$dbtbpre.'enewsclass where classid='.$GLOBALS[navclassid].'');$bname=$class_sql[bname];?>...
帝國CMS不同會員組查看文章權限判斷在靜態頁面的實現方法<?phprequire("class/connect.php");include("class/db_sql.php");include("class/config/config.php");include("data/dbcache/class.php");$link=db_connect...
$num="new";if($no>3){$num="old";}$listtemp='<li class="cl"><em class="'.$num.'">9416</em><a href="/l1/l1-1/295.html" target="_blank" title="[!-...