ECSHOP如何在首页调用标签云的所有标签

ecshop如何在首页调用所有标签云的标签呢?ECSHOP开发中心()教程介绍一下以下方法。

第一步:打开tag_cloud.php。将

assign_dynamic(‘tag_cloud’); $tags = get_tags(); if (!empty($tags)) { include_once(ROOT_PATH . ‘includes/lib_clips.php’); color_tag($tags); } $smarty->assign(‘tags’, $tags);这段代码复制下来。

第二步:打开index.php。找到$smarty->assign(‘shop_notice’, $_CFG[‘shop_notice’]); // 商店公告粘贴到这行代码下。

第三步:然后在index.dwt页面里,直接复制循环代码就可以了

<!– {if $tags} –> <!– 标签云开始 {foreach from=$tags item=tag}–> <span style="font-size:{$tag.size}; line-height:36px;"> <a href="{$tag.url}" style="color:{$tag.color}"> {if $tag.bold} <b>{$tag.tag_words|escape:html}</b> {else} {$tag.tag_words|escape:html} {/if} </a> <!– {if $tags_from eq ‘user’} –> <a href="user.php?act=act_del_tag&amp;tag_words={$tag.tag_words|escape:url}&amp;uid={$tag.user_id}" title="{$lang.drop}"> <img src="images/drop.gif" alt="{$lang.drop}" /> </a>&nbsp;&nbsp; <!– {/if} –> </span> <!– 标签云结束 {/foreach}–> <!– {else} –> <span style="margin:2px 10px; font-size:14px; line-height:36px;">{$lang.no_tag}</span> <!– {/if} –>

,旅游不在乎终点,而是在意途中的人和事还有那些美好的记忆和景色。

ECSHOP如何在首页调用标签云的所有标签

相关文章:

你感兴趣的文章:

标签云: