get_archives_link filter. Props codealsatian. fixes #5530 for trunk

git-svn-id: https://develop.svn.wordpress.org/trunk@7959 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Ryan Boren
2008-05-20 16:43:44 +00:00
parent 5800542926
commit 9d294b6342

View File

@@ -356,13 +356,17 @@ function get_archives_link($url, $text, $format = 'html', $before = '', $after =
$url = clean_url($url);
if ('link' == $format)
return "\t<link rel='archives' title='$title_text' href='$url' />\n";
$link_html = "\t<link rel='archives' title='$title_text' href='$url' />\n";
elseif ('option' == $format)
return "\t<option value='$url'>$before $text $after</option>\n";
$link_html = "\t<option value='$url'>$before $text $after</option>\n";
elseif ('html' == $format)
return "\t<li>$before<a href='$url' title='$title_text'>$text</a>$after</li>\n";
$link_html = "\t<li>$before<a href='$url' title='$title_text'>$text</a>$after</li>\n";
else // custom
return "\t$before<a href='$url' title='$title_text'>$text</a>$after\n";
$link_html = "\t$before<a href='$url' title='$title_text'>$text</a>$after\n";
$link_html = apply_filters( "get_archives_link", $link_html );
return $link_html;
}