visit this site. http://eventsinindia.com/event/2551 Now click on ''comments feed'' link . In both IE and Firefox it prompts to open a dialog box. As per feed validator the comments feed is a valid feed. (http://eventsinindia.com/feed/event_comments/2551). My question is what do I need to do so that when someone clicks on the commets feed either a subscribe with blog lines message comes or the feed content is displayed on the browser itself. Do I need to use XSLT? Here is the complete code. layout nil session :off @headers["Content-Type"] = "application/rss+xml" @comments = Comment.find(:all,:order => "created_on DESC", :limit => 20) xml.instruct! xml.rss "version" => "2.0", "xmlns:dc" => "http://purl.org/dc/elements/1.1/" do xml.channel do xml.title "Comments for event id #{@event.id} : EventsInIndia" xml.link url_for( :only_path => false,:controller => ''feed'',:action => ''event_comments'', :id => @event) xml.language "en-us" xml.copyright "Copyright 2006-2007 www.Flexaxis.com" xml.docs "http://blogs.law.harvard.edu/tech/rss" xml.image do xml.url "http://eventsinindia.com/images/eii_logo.gif" xml.link "http://eventsinindia.com/" xml.title "EventsInIndia.com" end xml.ttl "40" xml.description "List of events from all over India" for comment in @comments xml.item do xml.title "Comment for event id #{comment.event.id}: #{comment.event.name}" xml.link url_for( :only_path => false,:controller => ''event'',:action => comment.event.name_url,:anchor => "comment-#{comment.id}") xml.description feed_desc_for_comment(comment) xml.pubDate comment.created_on.rfc2822 xml.author "nospam-GMWn+aNOponQT0dZR+AlfA@public.gmane.org (#{get_name_of_commenter(comment,true)})" xml.guid url_for( :only_path => false,:controller => ''event'',:action => comment.event.name_url,:anchor => "comment-#{comment.id}") end end end end --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---
Neeraj Kumar wrote:> visit this site. > > http://eventsinindia.com/event/2551 > > Now click on ''comments feed'' link . In both IE and Firefox it prompts > to open a dialog box. > > As per feed validator the comments feed is a valid feed. > (http://eventsinindia.com/feed/event_comments/2551). > > My question is what do I need to do so that when someone clicks on the > commets feed either a subscribe with blog lines message comes or the > feed content is displayed on the browser itself. Do I need to use > XSLT? > > Here is the complete code. > > layout nil > session :off > @headers["Content-Type"] = "application/rss+xml" > @comments = Comment.find(:all,:order => "created_on DESC", :limit => 20) > > > > xml.instruct! > xml.rss "version" => "2.0", "xmlns:dc" => "http://purl.org/dc/elements/1.1/" do > xml.channel do > > > xml.title "Comments for event id #{@event.id} : EventsInIndia" > xml.link url_for( :only_path => false,:controller => > ''feed'',:action => ''event_comments'', :id => @event) > > xml.language "en-us" > xml.copyright "Copyright 2006-2007 www.Flexaxis.com" > xml.docs "http://blogs.law.harvard.edu/tech/rss" > xml.image do > xml.url "http://eventsinindia.com/images/eii_logo.gif" > xml.link "http://eventsinindia.com/" > xml.title "EventsInIndia.com" > end > > xml.ttl "40" > xml.description "List of events from all over India" > for comment in @comments > xml.item do > xml.title "Comment for event id #{comment.event.id}: > #{comment.event.name}" > xml.link url_for( :only_path => false,:controller => > ''event'',:action => comment.event.name_url,:anchor => > "comment-#{comment.id}") > xml.description feed_desc_for_comment(comment) > xml.pubDate comment.created_on.rfc2822 > xml.author "nospam-GMWn+aNOponQT0dZR+AlfA@public.gmane.org (#{get_name_of_commenter(comment,true)})" > xml.guid url_for( :only_path => false,:controller => > ''event'',:action => comment.event.name_url,:anchor => > "comment-#{comment.id}") > end > end > end > end > > > > >Work for me OK in Firefox 2 Chris --------------------------------------- http://www.autopendium.co.uk stuff about old cars --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---