Forum: Ruby on Rails IE6 CSS and Rails Routes

Announcement (2017-05-07): www.ruby-forum.com is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see rubyonrails.org/community and ruby-lang.org/en/community for other Rails- und Ruby-related community platforms.
(Guest)
on 2009-06-01 20:11
(Received via mailing list)
I dont know if anyone has come across this issue.

I have 2 different layouts for my app. both contain the same partial
with the same CSS files in the head.

in that i also have a IE6 CSS Hack file. Pretty standard.

The Problem in IE6
My issue is this. on any of my main pages that have named routes like
so
  map.privacy 'privacy-policy', :controller => "information", :action
=> "privacy_policy"
  map.admin 'dashboard', :controller => "admin", :action =>
"dashboard"
  map.home 'home', :controller => "information", :action => "home"
  map.search 'search', :controller => "information", :action =>
"search"

the CSS is picked up fine. but if i go to an action like /information/
home (this is in the url vs just home), where the controller is
listed. The CSS breaks and doesnt render the page correctly. But...
The file is still listed in the source(view source)..

very strange. any help would be great.

Thanks
Bob O (Guest)
on 2009-06-02 00:21
(Received via mailing list)
so i found out it was a pathing problem when i went to a url like /
controller/action, it caused my stylesheet path to break.

if i add a ../stylesheets/ie6stinks.css then it works for those pages
that have the controller in the url.

So now i have to conditionals that basically point to the same
stylesheet stylesheets/file.css and ../stylesheets/file.css seems
rather dumb to have to do it this way, does anyone have any ideas on
how to remedy or DRY up this issue?

Thanks

On Jun 1, 10:11 am, "removed_email_address@domain.invalid" 
<removed_email_address@domain.invalid>
p_W (Guest)
on 2009-06-02 00:49
(Received via mailing list)
Sorry if this is a dumb question, but are you putting actual link tags
in your templates or are you using 'stylesheet_link_tag()' ?
This topic is locked and can not be replied to.