However, some browsers still doesn't offer support for this feature and frequently we need to use some hack to make it work cross-browser.
There is a simple solution to treat this issue. It make the transparency works for browsers that support transparency and, for browser who doesn't, it still keel your layout elegant, even without transparency.
- Create a PNG transparent image with the desired opacity. The PNG can be 1px x 1px or, if it has some gradient effect, 1px width x correspondent height;
- On your CSS, add a rule like
element { background: (images/bg_transparent.png) [repetition] [horizontal-position] [vertical-position]; }
Ex.: .header { background: (images/bg_transparent.png) repeat-x 0 0; }
;)
Nenhum comentário:
Postar um comentário