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

git-svn-id: http://svn.automattic.com/wordpress/trunk@1669 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
michelvaldrighi 2004-09-16 13:15:07 +00:00
parent c6ba5da320
commit c0de7fb232
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() {