Hey I can''t figure out how to change the stylesheet using a selection list. In my application I want to have an option for the user to change the look of the site by selecting a different layout from a list. All it would say is something like Layout 1, Layout 2, etc. and then it would change to the other layout. It isn''t necessary to do it via Ajax or javascript or whatever would be used there, but if you know how to do that, it would be even better. Thanks. -- Posted via http://www.ruby-forum.com/.
Tom Dunn wrote:> Hey I can''t figure out how to change the stylesheet using a selection > list. In my application I want to have an option for the user to change > the look of the site by selecting a different layout from a list. All > it would say is something like Layout 1, Layout 2, etc. and then it > would change to the other layout. It isn''t necessary to do it via Ajax > or javascript or whatever would be used there, but if you know how to do > that, it would be even better. Thanks.1. Post on select changed 2. Save the selected value to session (select value is css file name) 3. stylesheet_link_tag use the session value. -- Posted via http://www.ruby-forum.com/.