单独输出tag链接地址

可以单独输出tag地址,需要修改funcations.php文件

function tags($widget, $split = ',', $default = NULL)
{
    /** 取出tags */
    if ($widget->tags) {
        $result = array();
        foreach ($widget->tags as $tag) {
            $result[] = $tag['permalink'];
        }

        echo implode($split, $result);
    } else {
        echo $default;
    }
}

调用

<?php tags($this); ?>

发表回复

您的电子邮箱地址不会被公开。 必填项已用 * 标注

Grow your business fast with

Suku