经测试,在channelartist标签中,直接调用{dede:field.currentstyle/}是无效的,需要更改一个文件。
在include/taglib下的channelartlist.lib.php文件中找到
$pv->Fields['typeurl'] = GetOneTypeUrlA($typeids[$i]);
找到后在下一行加一段
if($typeids[$i]['id'] == $refObj->TypeLink->TypeInfos['id'] || $typeids[$i]['id'] == $refObj->TypeLink->TypeInfos['topid'] ){$pv->Fields['currentstyle'] = $currentstyle ? $currentstyle : 'current';}else{$pv->Fields['currentstyle'] = '';}就可以
{dede:channelartlist typeid='top' currentstyle='active'}
....
{dede:field.currentstyle/}
...
{/dede:channelartlist}
具体实例
{dede:channelartlist typeid='top' currentstyle='active'}
<li class="{dede:field.currentstyle/}"><a href="{dede:field name='typeurl'/}">{dede:field name='typename'/}</a></li>
{/dede:channelartlist}这样使用了

Thomas2 年前
发表在:SQL Server2008报错:值不能为空[S35]
Thomas2 年前
发表在:解决Composer Installing dependencies from lock file你这都看不清了
1114 年前
发表在:Cetnos7 新手安装ZABBIX4.0.5详解教程有人嘛
Tyreunorm2020-08-27 22:51
发表在:php5.6 连接SQL SERVER<a href=https://mega...
耗子2020-04-08 15:02
发表在:写给正在创业的自己看到了,想写点。可能我开过这网站了,以后...
Thomas2019-11-19 19:57
发表在:twcms您的IP地址已改变,为了安全考虑,请重新登录这个好
酷喵2016-08-03 15:22
发表在:我家侄女成长记前排支持啦!
五爷2015-12-01 03:26
发表在:关于centos中的相关查看命令@admin:呵呵
admin2015-12-01 01:49
发表在:关于centos中的相关查看命令非常不错