関数 get_archives_link()
2014/12/25
関数 get_archives_link()
定義ファイル :/blog/wp-includes/general-template.php 3
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 | function get_archives_link($url, $text, $format = 'html', $before = '', $after = '') { $text = wptexturize($text); $url = esc_url($url); if ('link' == $format) $link_html = "\t<link rel='archives' title='" . esc_attr( $text ) . "' href='$url' />\n"; elseif ('option' == $format) $link_html = "\t<option value='$url'>$before $text $after</option>\n"; elseif ('html' == $format) $link_html = "\t<li>$before<a href='$url'>$text</a>$after</li>\n"; else // custom $link_html = "\t$before<a href='$url'>$text</a>$after\n"; $link_html = apply_filters( 'get_archives_link', $link_html ); return $link_html; } |