navigation
a webmaster learning community
     Home    Register     Search      Help      Login    
Sponsors

Shopping Cart Software
Ecommerce software integrated into Frontpage, Dreamweaver and Golive templates. No monthly fees and available in ASP and PHP versions.

Website Templates
We also have a wide selection of Dreamweaver, Expression Web and Frontpage templates as well as webmaster tools and CSS layouts.

Frontpage website templates
Creative Website Templates for FrontPage, Dreamweaver, Flash, SwishMax

Search Forums
 

Advanced search
Recent Posts

 Todays Posts
 Most Active posts
 Posts since last visit
 My Recent Posts
 Mark posts read

Microsoft MVP

 

Color around checkbox in a form

 
View related threads: (in this forum | in all forums)

Logged in as: Guest
Users viewing this topic: none
Printable Version 

All Forums >> Web Development >> Cascading Style Sheets >> Color around checkbox in a form
Page: [1]
 
Starhugger

 

Posts: 494
Joined: 4/12/2005
Status: offline

 
Color around checkbox in a form - 5/14/2007 19:32:46   
I'm trying to put a colour around the outside of a checkbox in a form. Curiously, it works in IE7 but not in Firefox. I found a webpage that shows how to do it with CSS. I've tried these two ways but I can't get it to work in Firefox.

CSS:
div.chkbox input { background-color: khaki }

FORM:
<div class="chkbox">
<input name="price2" type="checkbox" value="0.01" />
</div>

CSS: 
input.chkbox { background-color: khaki }

FORM:
<input name="price2" type="checkbox" class="chkbox" value="0.01" />

Any ideas?

Starhugger
Tailslide

 

Posts: 5915
Joined: 5/10/2005
From: Out here on the raggedy edge
Status: offline

 
RE: Color around checkbox in a form - 5/15/2007 2:33:59   
Forms are notoriously hard to style - the reason behind this (I think) is that it was thought that certain things should always look the same to avoid user confusion and forms were thought to be an important element that fell into this bracket (along with stuff like scrollbars).

I've found that this article: http://www.456bereastreet.com/lab/styling-form-controls-revisited/checkbox/ is the best on styling forms.

_____________________________

"My strategy is so simple an idiot could have devised it"
Little Blue Plane Web Design | Blood, Sweat & Rust - A Land Rover restoration project

(in reply to Starhugger)
coreybryant

 

Posts: 2422
Joined: 3/17/2002
From: Castle Rock CO USA
Status: offline

 
RE: Color around checkbox in a form - 5/15/2007 5:45:58   
Form Layout Example might help just a little, but I think it might be a few more years before we are actually allowed to mess with them

I played around once with text boxes and noticed a significant decline in the contacts. As suggested, it might be best to leave some things as is since people are used to some things

_____________________________

Corey R. Bryant
Merchant Accounts | Toll Free Numbers | My Blog | Expression Web Blog

(in reply to Tailslide)
Starhugger

 

Posts: 494
Joined: 4/12/2005
Status: offline

 
RE: Color around checkbox in a form - 5/15/2007 8:54:27   
Thanks, Tail and Corey. At least I *know* now that I'm up against a brick wall. Seems most browsers ignore styling of checkboxes, so no point anyway. And if you're right, Corey, that clickrates can go down, that's definitely not what I want.

Too bad. I had surrounded the checkboxes in khaki yellow, which made them look like little Suns! Very kewl 'n' groovy for my astrology website. :)

Oh well...

SH

(in reply to coreybryant)
Page:   [1]

All Forums >> Web Development >> Cascading Style Sheets >> Color around checkbox in a form
Page: [1]
Jump to: 1





New Messages No New Messages
Hot Topic w/ New Messages Hot Topic w/o New Messages
Locked w/ New Messages Locked w/o New Messages
 Post New Thread
 Reply to Message
 Post New Poll
 Submit Vote
 Delete My Own Post
 Delete My Own Thread
 Rate Posts