support for comment_type, while we move away from <*back /> stuff

git-svn-id: https://develop.svn.wordpress.org/trunk@1669 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
michelvaldrighi 2004-09-16 13:15:07 +00:00
parent 06a08d416a
commit 8f164348c6
1 changed files with 6 additions and 3 deletions

View File

@ -157,12 +157,15 @@ function comment_author_link() {
function comment_type($commenttxt = 'Comment', $trackbacktxt = 'Trackback', $pingbacktxt = 'Pingback') {
global $comment;
if (preg_match('|<trackback />|', $comment->comment_content))
if (preg_match('|<trackback />|', $comment->comment_content)
|| ('trackback' == $comment->comment_type)) {
echo $trackbacktxt;
elseif (preg_match('|<pingback />|', $comment->comment_content))
} elseif (preg_match('|<pingback />|', $comment->comment_content)
|| ('pingback' == $comment->comment_type)) {
echo $pingbacktxt;
else
} else {
echo $commenttxt;
}
}
function comment_author_url() {