Jump to content

using CSS to change radiobuttons


djamidin

Recommended Posts

One day, I tried to change the complete aspect of a combo box and I found out that it was not possible unless you create your own combo box object...I think it's the same problem with the radio buttons, you can change some global properties and that's all... but I'm not an expert in CSS...

Link to comment
Share on other sites

^^ Double post, see why we need moderators?Ya, i think that really the only thing you can change is the background. I haven't seen radio buttons ever that look different.

Link to comment
Share on other sites

the only way I've done it to replace the whole radio button with a graphic and use javascript to code its function like it was a radio button. The javascript changes the value of a hidden field - which would otherwise be the radio button. By using the combination of an image and the javascript functionality, you get full control over the look and feel of you radio buttons - again, the javascript (side from the radio button behavior) changes the value of the hidden field.

Link to comment
Share on other sites

now i want to change the colouring of the radiobuttons themselves.
<style type="text/css">#radiobrasileirinho {background-color:#708090;}</style><form><input type="radio" name="mycountry" value="brasil" id="radiobrasileirinho"><BR></form>

Try itbye

Link to comment
Share on other sites

Unfortunately radiobuttons, checkboxes and selectboxes are not stylable :)For the checkbox and radio, only the surrounding background, and with the select, only the background of the droplist and the text on it (excluding positioning styles)You can, as said, replace the input elements with own made grafics, but without the niceness of the input's functions :)

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...