You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Well, many of you are used to just replace the lack of min / max width / height for IE with fixed dimensions, right? But you don’t need to do it anymore. IE is not a strict standards browser and sometimes we can take advantage of this to code things that would be awful to see in standard CSS code.
You can, in this case, insert some IE expressions (basically, JavaScript code) to check current body width and adjust element’s width as follows:
This time we will need some IE filters to get the job done. You’ll have the standard markup, IE6 correction and IE8 correction.
IE corrections is based on gradient filter, that actually we put just one color to the beginning and the end, and BAM! We have a pretty RGBA background.
The first two digits should be the opacity and the last one should be the color itself. Don’t know why, it just don’t get the opacity right… Maybe its just a bug inside a bug :)
Sometimes we just need a quick way to get full screen backgrounds. Well, hope you don’t use JavaScript just to do this, because you can do it with a few lines of CSS.
The magic here is to set a div that goes fullscreen and inside it you can put a landscape, portrait or full sized image.
Many of you know about .clearfix method for correcting heights when you use floats. Well, in many of these cases, that amount of code could be replaced by just two lines:
.clearfix {
zoom:1;
overflow:hidden;
}
Pull quotes without images
blockquote:before {
display: block;
float: left;
margin:10px15px00;
font-size:100px; /* let's make it a big quote! */content: open-quote; /* here we define our :before as a smart quote. It could be any content, even the HTML entity alternative to this opening quote, that is “ */color:#bababa;
text-shadow:01px1px#909090;
}