步骤1:进入内容模型,在“列表附加字段”表单中加入redirecturl;
步骤2:修改/include/arc.listview.class.php文件,在$row['textlink'] = "<a href=’".$row['filename']."’>".$row['title']."</a>"; 下面加上:
if(ereg(‘j’,$row['flag']))
{
$row['textlink'] = "<a href=’".$row['redirecturl']."target=_blank’>".$row['title']."</a>";
$row['arcurl'] = $row['redirecturl'];
}
步骤3:修改/include/taglib/arclist.lib.php文件,找到252行 $row['textlink'] = "<a href=’".$row['filename']."’>".$row['title']."</a>";
后面加入
if(ereg(‘j’,$row['flag']))
{
$row['textlink'] = "<a href=’".$row['redirecturl']."target=_blank’>".$row['title']."</a>";
$row['arcurl'] = $row['redirecturl'];
}
OK了,模板页面不需要修改,测试一下吧