is there any solution to get support of CSS Gradient in firefox 3.5 and lower?
http://hacks.mozilla.org/2009/11/building-beautiful-buttons-with-css-gradients/
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
I would strongly advise you to just use a BG image. I know everyone can’t wait to start using all the latest whiz-bang CSS3 features, but we’re all just gonna have to wait for these parts of CSS3 to be adopted by the major browsers (which will happen before CSS3 reaches a W3C Recommendation).
Using vendor-specific extensions is a bad practice IMO and seems like a throw-back to the days when nobody cared about web standards, and web developers either, just coded for a single browser (along with tacky Designed for IE buttons), or had to write the same code multiple ways to support different browsers. All the major browsers now have support for PNG alpha layer transparency. So there’s really little advantage to force the use of CSS to generate gradients. It only introduces unnecessary code redundancy.
If you’re still set on absolutely not using BG images, then the only option is to use JavaScript. Here is a script that should work in Firefox 3 and up, perhaps even Firefox 2: JavaScript Gradient Roundrects.
The code would look something like:
But this is still a roundabout way to achieve a result that could be obtained with a simple 1x50px PNG image.