how do you want to modify it?


You can modify the background color, foreground color, font size and family
and width of a select. (Can't change the drop down tho)


CSS doesn't have any way of differentiating inputs (unless you use Attribute
selectors, but IE doesn't support those) so you need to define classes for
radio and checkboxes


For checkboxes and radio buttons, you can change the size via height and
width , background color or background-image. You can't change the shape of
either.


Here's some sample code to play around with.
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">


<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
<title></title>
<style type="text/css">
/*<![CDATA[*/
select{
  background-color: blue;
  width: 300px;
  border: none;
  color:white;
  padding-left: 4em;
  font-size: 3em;
}

input.checkbox
{
  background-color: Fuchsia;
  width: 25px;
  height: 50px;
  color: red;
}

/*]]>*/
</style>
</head>


<body>
<form>
<select><option>hi</option></select><br />
<input type="checkbox" class="checkbox" /><br />
<input type="radio" class="checkbox" />
</form>
</body>
</html>

  _____  

From: Nathan R. Jessop [mailto:[EMAIL PROTECTED]
Sent: Thursday, May 06, 2004 3:29 PM
To: CF-Community
Subject: re: CF and CSS with <input> boxes etc

Hi,

Is there a way to modify the default dropdown selection box using CSS?

Can the checkboxes and radio buttons also be modified?

---------------------------------------------------
Colonel Nathan R. Jessop
Commanding Officer
Marine Ground Forces
Guatanamo Bay, Cuba
---------------------------------------------------
  _____
[Todays Threads] [This Message] [Subscription] [Fast Unsubscribe] [User Settings]

Reply via email to