I’ve done some behind-the-scenes stuff to my feeds that aren’t in the WordPress defaults. The first is something that you won’t notice (because I do not publicize comments feeds all that much); to make my comments feed validate properly, I replaced the <author> tag in the file that generates the comments feed with <dc:creator> (I also needed to add a namespace reference to the site that hosts the specs for that tag to enable that; it’s in the main RSS 2.0 feed). It seems that the <author> tag that the default WP comment feed generator forces is supposed to have an e-mail address attached to it.
The second is something some of you may notice, at least if you can read comments directly from the main feed. Using Nick Schweitzer‘s feed as a template, I’ve figured out how to add the number of comments to the feed so some feed readers (like SharpReader, and unlike Google Reader) will tell me how many comments are on a particular post. That involved adding a namespace reference and putting the <slash:comments> tag in.
More geekspeak below the fold…
For the comments fix, I needed to edit the /wp-includes/feed-rss2-comments.php add the following line within the <rss version…> tag – xmlns:dc=”http://purl.org/dc/elements/1.1/”, and then replace the <author> and </author> tags with <dc:creator> and </dc:creator> (respectively).
The main feed enhancement involved changing the /wp-includes/feed-rss2.php file. First, I had to add the following line within the <rss version…> tag – xmlns:slash=”http://purl.org/rss/1.0/modules/slash/”. Then, I added the following line between the <item> and </item> tags – <slash:comments><?php echo comments_number(‘0’, ‘1’, ‘%’); ?></slash:comments>. Do note that I could not simply use the parentheses without the text; by default, that WordPress function passes along additional text).
Of course if you used DasBlog, then you’d get all this out of the box. ;)