get_archives

函数


get_archives ( $type = '', $limit = '', $format = 'html', $before = '', $after = '', $show_post_count = false )
参数
  • (string)
    $type
    Required:
    Default: (empty)
  • (string)
    $limit
    Required:
    Default: (empty)
  • (string)
    $format
    Required:
    Default: ‘html’
  • (string)
    $before
    Required:
    Default: (empty)
  • (string)
    $after
    Required:
    Default: (empty)
  • (bool)
    $show_post_count
    Required:
    Default: false
返回值
  • (string|null)
相关
  • wp_get_archives()
定义位置
  • wp-includes/deprecated.php
    , line 785
引入
0.71
弃用
2.1.0

Retrieves a list of archives.

function get_archives($type='', $limit='', $format='html', $before = '', $after = '', $show_post_count = false) {
	_deprecated_function( __FUNCTION__, '2.1.0', 'wp_get_archives()' );
	$args = compact('type', 'limit', 'format', 'before', 'after', 'show_post_count');
	return wp_get_archives($args);
}