html - The sequence of execution of CSS -
i curious know sequence of execution of statements in css file. have following css in css file :
/* screen width larger 800px */ @media screen (min-width: 800px) { .indexphototd { width:200px !important; } .indexphoto { width:200px !important; } } /* screen width larger 1200px */ @media screen (min-width: 1200px) { .indexphototd { width:300px !important; } .indexphoto { width:300px !important; } } /* default setting */ .indexphototd { width:500px !important; } .indexphoto { width:500px !important; }
in code above have declared 2 types of settings of 2 classes in 2 different screen sizes, , after have mentioned 2 statements without restriction on screen sizes (that is, default).
my objective is, screen size not fall 2 groups above, has take default value set in 3rd 1 below.
but wondering if default settings override screen-size specific settings since have inserted default setting @ end. have put @ beginning? please let me know sequence of execution in css. know css not programming language. new web development , learning these minute stuff. please me. thanks.
isaac
later statements override earlier ones, you'll have go general specific.
/* general css here */ /* css min-width 800 here, overides general */ /* css min-width 1024 here, overides both general , 800 */
Comments
Post a Comment