0

是否有关于如何将 URL 结构插入小部件存档的解决方案?

现在,URL 结构如下:-http://example.com/2012

我希望它是:-http://example.com/ sub /2012

该函数的文档是这样的:http ://codex.wordpress.org/Function_Reference/wp_get_archives但没有找到更改 URL 结构的语句。也许有解决办法?

代码如下:

function set_widget_archives_type($args) {
    $args = array(
        'type' => 'yearly',
    );
    return $args;
}
add_filter('widget_archives_args','set_widget_archives_type');
4

0 回答 0