列表调用两个关联栏目的内容
{eyou:arclist}
标题:{$field.title}
{eyou:assign name='writer' value='$field.author'/}
<!-- 获取作者名称 -->
{eyou:sql sql='SELECT aid,author,litpic FROM ey_archives WHERE author = "$writer" AND typeid="345" order by aid desc limit 3' cachetime='-1'}
{eyou:arcview aid="$field.aid" id="field2"}
<li>作品:<a href="{$field2.arcurl}">{$field2.title}</a></li>
{/eyou:arcview}
{/eyou:sql}
{/eyou:arclist}
<!-- typeid="345"可以改成放作品的栏目ID -->
相关文章