首页 > 教程 >
用织梦dedecms做网站如何使arc支持也支持current
2023-02-27教程围观次
简介目前,网站建设行业中,用织梦dedecms做网站的人也越来越多。当中可能会遇到很多问题。今天说一下当网站建设类似于关于我们多篇文章时,需要高亮功能的话如何实现。$channelid=$ctag->GetAtt('channelid');在下面插入:$currentstyle=$ctag->GetAtt('currentstyle');2、查找:returnlib_arclistDone($refO
目前,网站建设行业中,用织梦dedecms做网站的人也越来越多。当中可能会遇到很多问题。今天说一下
当网站建设类似于关于我们多篇文章时,需要高亮功能的话如何实现。
$channelid = $ctag->GetAtt('channelid');
在下面插入:
$currentstyle = $ctag->GetAtt('currentstyle');
2、查找:
return lib_arclistDone
(
$refObj, $ctag, $typeid, $ctag->GetAtt('row'), $ctag->GetAtt('col'), $ len, $infolen,
$ctag->GetAtt('imgwidth'), $ctag->GetAtt('imgheight'), $listtype, $orderby,
$ctag->GetAtt('keyword'), $innertext, $envs['aid'], $ctag->GetAtt('idlist'), $channelid,
$ctag->GetAtt('limit'), $flag,$ctag->GetAtt('orderway'), $ctag->GetAtt('subday'), $ctag->GetAtt('noflag'),
$tagid,$pagesize,$isweight
);
替换为:
return lib_arclistDone
(
$refObj, $ctag, $typeid, $ctag->GetAtt('row'), $ctag->GetAtt('col'), $ len, $infolen,
$ctag->GetAtt('imgwidth'), $ctag->GetAtt('imgheight'), $listtype, $orderby,
$ctag->GetAtt('keyword'), $innertext, $envs['aid'], $ctag->GetAtt('idlist'), $channelid,
$ctag->GetAtt('limit'), $flag,$ctag->GetAtt('orderway'), $ctag->GetAtt('subday'), $ctag->GetAtt('noflag'),
$tagid,$pagesize,$isweight,$currentstyle
);
其实就是在调用函数的最后加了一个$currentstyle实参
3、查找
function lib_arclistDone(&$refObj, &$ctag, $typeid=0, $row=10, $col=1, $ len=30, $infolen=160,
$imgwidth=120, $imgheight=90, $listtype='all', $orderby='default', $keyword='',
$innertext='', $arcid=0, $idlist='', $channelid=0, $limit='', $att='', $order='desc', $subday=0, $noflag='',$tagid='', $pagesize=0, $isweight='N')
替换为:
function lib_arclistDone(&$refObj, &$ctag, $typeid=0, $row=10, $col=1, $ len=30, $infolen=160,
$imgwidth=120, $imgheight=90, $listtype='all', $orderby='default', $keyword='',
$innertext='', $arcid=0, $idlist='', $channelid=0, $limit='', $att='',$order='desc', $subday=0, $noflag='',$tagid='', $pagesize=0,$isweight='N',$currentstyle='')
其实就是在函数后面加了一个$currentstyle=''形参
4、查找
$row['text '] = "".$row[' ']."";
在下面插入:
if($currentstyle && $row['id']==$arcid){
$currentstyle = str_replace('~type ~', $row['filename'], $currentstyle);
$row['currentstyle'] = str_replace('~typename~', $row[' '], $currentstyle);
}
保存,即可。
调用方法:
{dede:arclist len='42' row='10' currentstyle="
~typename~
"}
[field:array runphp='yes']
if(@me['currentstyle']){
@me = @me['currentstyle'];
}else{
@me = "
{@me[' ']}
";
}
[/field:array]
{/dede:arclist}
下载链接:网站源码/小程序源码/网站模板下载
下载排行
- 游戏陪玩语音聊天系统3.0商业升级独立版本源码
- 苹果CMS影视系统成品站打包源码+电影先生6.1.1模板优化版+15W数据
- 主题巴巴WordPress主题合辑打包下载+主题巴巴SEO插件
- 最新版手机软件App下载排行网站源码/App应用商店源码
- 英皇cms影视网站系统源码/多种模板+自带采集+支持APP
- 抽奖系统源码_微信抽奖系统PHP源码开源
- 小旋风万能蜘蛛池x9.02开心版/站长必备SEO/永久使用/带教程
- 礼品包装品牌定制企业静态HTML网站模板
- 1元云购商城 1元夺宝网站源码 短信/微信登录/QQ互联/多支付接口 完美修复版
- ECSHOP模板万表网商城整站源码豪华版 带安卓苹果APP源码