11175
(-- --)
1
I have a two style sheets. One for IE and one for all the other
browsers.
Now I need browser detection so I know which style sheet to load.
I understand that there is request.user_agent.
My question is what is the string I need to test for?
Thanks for your time in advance,
Mitch
Achithyn
(Achithyn)
2
Why not simply use an HTML conditional statement such as:
<!--[if IE]> IE Conditional Comment: Internet Explorer
<![endif]-->
I haven't used this before, though TextMate has it built in under
conditionals within the HTML commands. This one would actually be
better:
<!--[if !IE]><!--> IE Conditional Comment: NOT Internet Explorer
<!-- <![endif]-->
Let me know if that helps!
~Dustin Tigner
bphogan
(Brian P. Hogan)
3
I’m confused… why would conditional comments prevent you from changing the font size?
Set it in the main style sheet, override it in the IE sheet.
Hi Mitch,
Mitchell Gould wrote:
I have a two style sheets. One for IE and one
for all the other browsers.
Now I need browser detection so I know which
style sheet to load.
I understand that there is request.user_agent.
My question is what is the string I need to test for?
This thread should help.
http://lists.rubyonrails.org/pipermail/rails/2006-April/032625.html
Best regards,
Bill
11175
(-- --)
5
Bill Walton wrote:
Hi Mitch,
Mitchell Gould wrote:
I have a two style sheets. One for IE and one
for all the other browsers.
Now I need browser detection so I know which
style sheet to load.
I understand that there is request.user_agent.
My question is what is the string I need to test for?
This thread should help.
http://lists.rubyonrails.org/pipermail/rails/2006-April/032625.html
Best regards,
Bill
Thanks Bill that will come in handy,
Mitch