Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Why put two different position rules in one css selector

Tags:

css

Found this is some example CSS I was reading and I'm having a hard time determining why there are two position rules in one selector.

#Div
{
     position:fixed !important;
     position:absolute;
}

What does this accomplish? Isn't the !important element always going to override the position: absolute?

like image 766
user772110 Avatar asked Apr 05 '12 00:04

user772110


1 Answers

All browsers that support position:fixed will use it, the others fall back to absolute.

like image 126
binarious Avatar answered Sep 27 '22 15:09

binarious