|
|
|
|
Thread title: IF/End if in CSS |
|
|
|
|
|
Thread tools
Search this thread
Display Modes
|
|
07-14-2006, 11:51 PM
|
#1
|
Status: Member
Join date: Mar 2006
Location: London, Ontario, Canada
Expertise: Design & Photograph
Software: Photoshop, Dreamweaver, Chrome
Posts: 182
|
IF/End if in CSS
I am trying to make it so that if the user is using IE it tells the class i am using to put overflow:scroll; on it.
Is this posible?
|
|
07-15-2006, 12:00 AM
|
#2
|
Status: Superstar
Join date: Apr 2005
Location:
Expertise:
Software:
Posts: 4,449
|
Yes, using a conditional statement..
<!--[if IE]><style type="text/css">@import"global_ie.css";</style><![endif]-->
Is an example for external CSS
<!--[if IE]><style type="text/css"> #css { here; }</style><![endif]-->
Is an example for internal CSS
|
|
07-15-2006, 12:13 AM
|
#3
|
Status: Member
Join date: Mar 2006
Location: London, Ontario, Canada
Expertise: Design & Photograph
Software: Photoshop, Dreamweaver, Chrome
Posts: 182
|
|
|
07-15-2006, 12:17 AM
|
#4
|
Status: I love this place
Join date: Jan 2005
Location: UK, Birmingham
Expertise:
Software:
Posts: 606
|
Jeff I was wondering wouldn't it be better/quicker to use a * html hack or is there something wrong with this?
|
|
07-15-2006, 12:31 AM
|
#5
|
Status: Member
Join date: Feb 2005
Location: UK
Expertise:
Software:
Posts: 335
|
I would do this:
Code:
div#poop
{
overflow: visible !important;
overflow: scroll;
}
|
|
07-15-2006, 12:48 AM
|
#6
|
Status: Member
Join date: Mar 2006
Location: London, Ontario, Canada
Expertise: Design & Photograph
Software: Photoshop, Dreamweaver, Chrome
Posts: 182
|
Jonny how does that work can you explain it please.
|
|
07-16-2006, 06:34 PM
|
#7
|
Status: Member
Join date: Feb 2005
Location: UK
Expertise:
Software:
Posts: 335
|
IE6 and older browsers don't support the !importance rule so they will just cascade and set the overflow to scroll instead.
|
|
|
|
|
|
|
|
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
|
|
|
|