Is it possible to have one layout extend another one? For example: normal.rhtml: <html> <stuff /> <%= @content_for_layout %> </html> extra_stuff.rhtml somehow extends normal.rhtml: <morestuff /> <%= @content_for_layout %> <evenmorestuff /> So any page that uses extra_stuff as its layout looks like this: <html> <stuff /> <morestuff /> <%= @content_for_layout %> <evenmorestuff /> </html> Is this possible to do? It would be really handy. Thanks in advance for the help! --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---
> Is it possible to have one layout extend another one? > > Is this possible to do? It would be really handy. Thanks in advancehttp://www.google.com/search?q=nested+layouts+in+rails 4th link. --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---
Dave, It looks very much like DRYML, part of Habo. http://hobocentral.net/manual/chapters/3_dryml.html For my case simple segment layout I''ll just use helper method: http://www.pluitsolutions.com/2007/02/07/rails-an-adventure-with-dont-repeat -yourself-dry-template/ Herry -----Original Message----- From: rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org [mailto:rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org] On Behalf Of Dave Sent: 27 April 2007 09:37 To: Ruby on Rails: Talk Subject: [Rails] Is inheiritance possible in layouts? Is it possible to have one layout extend another one? For example: normal.rhtml: <html> <stuff /> <%= @content_for_layout %> </html> extra_stuff.rhtml somehow extends normal.rhtml: <morestuff /> <%= @content_for_layout %> <evenmorestuff /> So any page that uses extra_stuff as its layout looks like this: <html> <stuff /> <morestuff /> <%= @content_for_layout %> <evenmorestuff /> </html> Is this possible to do? It would be really handy. Thanks in advance for the help! --~--~---------~--~----~------------~-------~--~----~ 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@googlegroups.com For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---