diff --git a/b2-include/b2template.functions.php b/b2-include/b2template.functions.php index 645618f8c2..026160980f 100644 --- a/b2-include/b2template.functions.php +++ b/b2-include/b2template.functions.php @@ -487,6 +487,15 @@ function the_author_posts() { /***** Post tags *****/ +function get_the_password_form() { + $output = "
+

This post is password protected. To view it please enter your password below:

+

+
+ "; + return $output; +} + function the_ID() { global $id; echo $id; @@ -596,11 +605,7 @@ function get_the_content($more_link_text='(more...)', $stripteaser=0, $more_file if (!empty($post->post_password)) { // if there's a password if ($HTTP_COOKIE_VARS['wp-postpass'] != $post->post_password) { // and it doesn't match the cookie - $output = "
-

This post is password protected. To view it please enter your password below:

-

-
- "; + $output = get_the_password_form(); return $output; } } @@ -848,10 +853,6 @@ function next_post($format='%', $next='next post: ', $title='yes', $in_same_cat= } } - - - - function next_posts($max_page = 0) { // original by cfactor at cooltux.org global $HTTP_SERVER_VARS, $siteurl, $blogfilename, $p, $paged, $what_to_show, $pagenow; global $querystring_start, $querystring_equal, $querystring_separator; @@ -1311,6 +1312,46 @@ function comment_time($d='') { } } +function comments_rss_link($link_text='Comments RSS', $commentsrssfilename = 'wp-commentsrss2.php') { + global $id; + global $querystring_start, $querystring_equal, $querystring_separator; + $url = $commentsrssfilename.$querystring_start.'p'.$querystring_equal.$id; + $url = ''.$link_text.''; + echo $url; +} + +function comment_author_rss() { + global $comment; + echo strip_tags(stripslashes($comment->comment_author)); +} + +function comment_text_rss() { + global $comment; + $comment_text = stripslashes($comment->comment_content); + $comment_text = str_replace('', '', $comment_text); + $comment_text = str_replace('', '', $comment_text); + $comment_text = convert_chars($comment_text); + $comment_text = convert_bbcode($comment_text); + $comment_text = convert_gmcode($comment_text); + $comment_text = convert_smilies($comment_text); + $comment_text = apply_filters('comment_text', $comment_text); + $comment_text = strip_tags($comment_text); + $comment_text = htmlspecialchars($comment_text); + echo $comment_text; +} + +function comment_link_rss() { + global $comment,$postdata,$pagenow,$siteurl,$blogfilename; + global $querystring_start, $querystring_equal, $querystring_separator; + echo $siteurl.'/'.$blogfilename.$querystring_start.'p'.$querystring_equal.$comment->comment_post_ID.$querystring_separator.'c'.$querystring_equal.'1#comments'; +} + +function permalink_comments_rss() { + global $comment,$postdata,$pagenow,$siteurl,$blogfilename; + global $querystring_start, $querystring_equal, $querystring_separator; + echo $siteurl.'/'.$blogfilename.$querystring_start.'p'.$querystring_equal.$comment->comment_post_ID.$querystring_separator.'c'.$querystring_equal.'1'; +} + /***** // Comment tags *****/