Changeset 650 for trunk/wp-includes/template-functions.php
- Timestamp:
- 12/24/2003 08:43:04 PM (23 years ago)
- File:
-
- 1 edited
-
trunk/wp-includes/template-functions.php (modified) (6 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/wp-includes/template-functions.php
r643 r650 1525 1525 function comment_author() { 1526 1526 global $comment; 1527 if (!empty($comment->comment_author)) { 1528 echo htmlspecialchars(stripslashes($comment->comment_author)); 1527 $author = stripslashes(stripslashes($comment->comment_author)); 1528 $author = apply_filters('comment_auther', $author); 1529 if (!empty($author)) { 1530 echo htmlspecialchars($comment->comment_author); 1529 1531 } 1530 1532 else { … … 1535 1537 function comment_author_email() { 1536 1538 global $comment; 1539 $email = stripslashes(stripslashes($comment->comment_author_email)); 1540 1537 1541 echo antispambot(stripslashes($comment->comment_author_email)); 1538 1542 } … … 1548 1552 1549 1553 $url = str_replace('http://url', '', $url); 1550 1554 $url = preg_replace('|[^a-z0-9-_.,/:]|i', '', $url); 1551 1555 if (empty($url) && empty($email)) { 1552 1556 echo $author; … … 1579 1583 // convert & into & 1580 1584 $url = preg_replace('/&([^#])(?![a-z]{2,8};)/', '&$1', $url); 1585 $url = preg_replace('|[^a-z0-9-_.,/:]|i', '', $url); 1581 1586 if ($url != 'http://url') { 1582 1587 echo $url; … … 1600 1605 $url = preg_replace('/&([^#])(?![a-z]{2,8};)/', '&$1', $url); 1601 1606 $url = (!stristr($url, '://')) ? 'http://'.$url : $url; 1607 $url = preg_replace('|[^a-z0-9-_.,/:]|i', '', $url); 1602 1608 if ((!empty($url)) && ($url != 'http://') && ($url != 'http://url')) { 1603 1609 $display = ($linktext != '') ? $linktext : stripslashes($url); 1604 1610 echo $before; 1605 echo '<a href="'.stripslashes($url).'" target="_blank">'.$display.'</a>';1611 echo '<a href="'.stripslashes($url).'" rel="external">'.$display.'</a>'; 1606 1612 echo $after; 1607 1613 } … … 1680 1686 1681 1687 function comment_link_rss() { 1682 global $comment,$postdata,$pagenow,$siteurl,$blogfilename; 1683 global $querystring_start, $querystring_equal, $querystring_separator; 1688 global $comment; 1684 1689 echo get_permalink($comment->comment_post_ID).'#comments'; 1685 1690 } 1686 1691 1687 1692 function permalink_comments_rss() { 1688 global $comment,$postdata,$pagenow,$siteurl,$blogfilename; 1689 global $querystring_start, $querystring_equal, $querystring_separator; 1693 global $comment; 1690 1694 echo get_permalink($comment->comment_post_ID); 1691 1695 }
Note:
See TracChangeset
for help on using the changeset viewer.
![(please configure the [header_logo] section in trac.ini)](/chrome/site/your_project_logo.png)