In: CSS
16 Sep 2010Tweet To have rounded corners on your page elements you should only use border-radius, as CSS property. However – in reality it won’t work on all browsers. To make CSS rounded corners work in IE, you should use snippet shown. To use border-radius CSS property in IE, you will need border-radius.htc file. This is a [...]
In: CSS
9 Aug 2010Tweet Until recent, not many of CSS3 properties have been used. There is one function though that has been used a while: opacity. To use opacity on your website, you should setup opacity property in your CSS file, like shown in snippet. 1 2 3 4 5 div.my_box { opacity: 0.5; width: 100px; height: 100px; [...]
In: CSS
26 Jul 2010Tweet To position div in center of your HTML, you should set divs margin to auto. Use style from following snippet to position your div in center of html. 1 2 3 4 5 6 7 8 9 10 11 12 13 14 <head> <style> div.center { margin: 0 auto; width: 200px; height: 200px; background: [...]
Tweet In this snippet we shall see what is the way of using CSS file with no cache. In order to achieve this, we could include different CSS file every time. We won’t actually include different CSS file, but we shall send new param. This way, we will trick browser into thinking that there is [...]
Tweet Whenever writing CSS for a new website, it is a good practice to use CSS reset before writing any line of code. It is a good practice doing this, since various browsers have different default settings, and you want to start on good foundations. You probably don’t want to ignore browser compatibility issue. I [...]