[wp-hackers] [patch] support for <slash:comments> / rss bandit in wp-rss2.php

Robert Deaton false.hopes at gmail.com
Sun Jan 23 18:43:46 GMT 2005


Just a note for the future, PHP doesn't compile. But, I did test it,
seems to work fine here.


On Sun, 23 Jan 2005 19:28:14 +0100, Axel Kollmorgen <axel at kollmorgen.net> wrote:
> <slash:comments>, part of the slash rss 1.0 module / namespace /
> extension [1], allows rss 1.0 / 2.0 feeds to expose the number of
> comments currently made on feed items [2]. this feature is used by many
> rss generators and aggregators, among others by my favourite rss reader
> [3]. rss bandit uses <slash:comments> to determine if an item has (new)
> comments [4]. if it doesn't find <slash:comments>, it considers the item
> to not have comments at all, even if the feed supports <wfw:commentRss>
> (as wordpress does).
> 
> this 2-line-patch for CVS HEAD as of today adds support for
> <slash:comments> to wp-rss2.php and makes it display lovely threaded in
> rss bandit. i (and i guess some more rss bandit users) would much
> appreciate if you could test this patch and incorporate it into
> wordpress. thanks a lot in advance!
> 
> on a related note: i tried to submit this patch via mosquito, but never
> got the signup mail and password (username: ax). i then realized that
> this is probably because your mail server is listed in at least one rbl
> [5-7]. you might want to consider getting off of them.
> 
> thanks for listening!
> 
> [1] http://purl.org/rss/1.0/modules/slash/
> [2] http://www.sellsbrothers.com/spout/#End-To-End_RSS_+_Comments
> [3] http://rssbandit.org/
> [4]
> http://sourceforge.net/tracker/?group_id=96589&atid=615248&func=detail&aid=1064745
> , comment by t_rendelmann
> [5] http://dnsstuff.com/tools/ip4r.ch?ip=70.84.29.148
> [6] http://www.five-ten-sg.com/blackhole.php?ip=70.84.29.148
> [7] http://openrbl.org/ip/70/84/29/148.htm
> 
> --
> ax
> 
> Meets quality standards:  Compiles without errors.
> 
> 
> Index: wp-rss2.php
> ===================================================================
> RCS file: /cvsroot/cafelog/wordpress/wp-rss2.php,v
> retrieving revision 1.33
> diff -u -r1.33 wp-rss2.php
> --- wp-rss2.php 22 Jan 2005 03:45:35 -0000      1.33
> +++ wp-rss2.php 23 Jan 2005 13:47:38 -0000
> @@ -13,8 +13,9 @@
>  <?php echo '<?xml version="1.0" encoding="'.get_settings('blog_charset').'"?'.'>'; ?>
> 
>  <!-- generator="wordpress/<?php bloginfo_rss('version') ?>" -->
> -<rss version="2.0"
> +<rss version="2.0"
>         xmlns:content="http://purl.org/rss/1.0/modules/content/"
> +       xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
>         xmlns:wfw="http://wellformedweb.org/CommentAPI/"
>  >
> 
> @@ -44,6 +45,7 @@
>                 <content:encoded><![CDATA[<?php the_excerpt_rss() ?>]]></content:encoded>
>         <?php endif; ?>
>  <?php endif; ?>
> +               <slash:comments><?php echo $comment_count_cache[$post->ID]; ?></slash:comments>
>                 <wfw:commentRSS><?php echo comments_rss(); ?></wfw:commentRSS>
>  <?php rss_enclosure(); ?>
>         </item>
> 
> 
> _______________________________________________
> hackers mailing list
> hackers at wordpress.org
> http://wordpress.org/mailman/listinfo/hackers
> 
> 
> 


-- 
--Robert Deaton
http://anothersadsong.com


More information about the hackers mailing list