[Ror-es] XML y formato de fecha RFC2822
Hernan MaguiƱa
Fri May 22 17:50:58 GMT 2009
- Previous message: [Ror-es] Consulta-Meta tags!!!
- Next message: [Ror-es] XML y formato de fecha RFC2822
-
Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Hola a todos y desde ya gracias por las posibles respuestas,
he creado un metodo dentro de mi controlador "tools" llamado "feed",
el codigo a continuacion:
def feed
@tools = Tool.find(:all, :order => "created_at DESC", :limit => 5)
respond_to do |format|
format.xml { render :layout => false}
end
end
y he creado la vista que se llama "feed.rxml", a continuacion el codigo:
xml.instruct! :xml, :version=>"1.0"
xml.rss(:version=>"2.0"){
xml.channel{
xml.title("Tools")
xml.link("http://www.yoursite.tld/")
xml.description("What your site is all about.")
xml.language('en-us')
xml.image do
xml.url'http://www.yoursite.tld/images/tools.jpg'
xml.title 'Tools'
xml.width 110
xml.height 160
end
for tool in @tools
xml.item do
xml.title(tool.name)
xml.description(tool.excerpt)
xml.pubDate(tool.created_at.rfc2822)
xml.link(url_for(:only_path =>
false, :controller=>'tools', :action=>'show', :id=>tool))
xml.guid(url_for(:only_path =>
false, :controller=>'tools', :action=>'show', :id=>tool))
end
end
}
}
el problema que tengo ocurre en mi servidor de produccion con ip
publica, no funciona, no recibo respuesta alguna, simplemente la
pagina en blanco.
He visto que si retiro .rfc2822 el xml se ejecuta bien, he googleado y
mucho y no encuentro pistas, en mi maquina de desarrollo todo funciona
ok, en ambas uso ubuntu 8.04 + rails 2.3.2 + apache2 + mysql 5 +
passenger
Alguien me podria dar una pista si me falta instalar algo en mi
servidor de produccion?
Saludos,
Hernan
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.simplelogica.net/pipermail/ror-es/attachments/20090522/b6c03d7e/attachment.htm
- Previous message: [Ror-es] Consulta-Meta tags!!!
- Next message: [Ror-es] XML y formato de fecha RFC2822
-
Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]