'yearly',
'show_post_count' => 1,
'format' => 'custom',
'before' => '
',
'after' => '',
'echo' => 0,
));
preg_match_all('/(.*?href=(\'|")(.*?(\d{4}).*?)(\'|").*?)<\/li>/', $yearstr, $matches, PREG_SET_ORDER);
$datelist = array();
foreach($matches as $match) {
$html = $match[1];
$year = $match[4];
$datelist[$year]['html'] = $html;
}
$monthstr = wp_get_archives(array(
'type' => 'monthly',
'show_post_count' => 1,
'format' => 'custom',
'before' => '',
'after' => '',
'echo' => 0,
));
preg_match_all('/(.*?href=(\'|")(.*?(\d{4}).*?(\d{2}).*?)(\'|").*?)<\/li>/', $monthstr, $matches, PREG_SET_ORDER);
foreach($matches as $match) {
$html = $match[1];
$year = $match[4];
$month = $match[5];
$datelist[$year]['month'][$month]['html'] = $html;
}
wp_enqueue_style('tanglha-page-archives', get_template_directory_uri().'/css/page-archives.css', array('tanglha-archive'), false);
wp_enqueue_script('tanglha-page-archives', get_template_directory_uri().'/js/page-archives.js', array('tanglha-common'), false);
get_header();
?>
$yd) {
echo '- '.$yd['html'].'
';
foreach ($yd['month'] as $month => $md) {
echo '- '.$md['html'].'
';
}
echo '
';
}
?>
1,
'hide_empty ' => 0,
'title_li' => '',
)); ?>
'array',
'orderby' => 'name',
'echo' => 0,
'smallest' => 10,
'largest' => 40,
));
/*$outtags = array();
for($i = count($tags); $i > 0; $i--) {
if($i % 2 ==0) {
array_push($outtags, array_pop($tags));
}else {
array_unshift($outtags, array_pop($tags));
}
}*/
echo '- '.implode('
- ', $tags).'
';
?>