this rss feed question was resolved but now when i tried this code <a href="<?php echo get_post_comments_feed_link($feed); ?>">RSS feed of this post</a> on my archives page,then i am getting the wrong url feed what i want is when i click on the this feed, then i should get all the feeds of that current page which means, my url is this http://mbas.in/location/mba-in-ghana where location is my custom taxonomy, if i write this in url http://mbas.in/location/mba-in-ghana/feed then i get all the feeds of that page, but if i write the code and i click on the link then it is giving me feeds of this url http://mbas.in/university-ghana-business-school/emba/feed this is the first post of my that page,

what is the problem with this?

  • Lost me on so many levels. What's up with overwriting old question with new one? What post comments feed has to do custom taxonomies?? I gave you links both to get_post_comments_feed_link() and feeds in general, had you even tried to go through those? – Rarst Dec 20 '10 at 6:07
  • i just want a link above my archives page, where if i click on that link then it should redirect me to the feeds of that page, i tried the code <a href="<?php echo get_post_comments_feed_link($feed); ?>">RSS feed of this post</a> but it is giving me wrong url – Niraj Chauhan Dec 20 '10 at 6:27

Not entirely sure. This is template tag and should be used in Loop, but for single post page it works fine most of the time even outside of Loop. Seems to from quick test.

Disregard that. The issue is you were forgetting to echo it. :)

Also there is specialized template tag for comment feeds: get_post_comments_feed_link().

and is there any plugin where as soon as i publish a new post, automatically the rss feed is also created of it???

Not sure what you mean here. When post is published it automatically appears in main site's feed.

  • hey thanks get_post_comments_feed_link() worked, and i am looking for a plugin, where if i publish a new post, automatically it should also post in feed – Niraj Chauhan Dec 16 '10 at 8:34
  • @ntechi still not sure... do you want something different from native feed options? – Rarst Dec 16 '10 at 8:46

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.