|
|
|
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
#1
|
|||
|
|||
|
CSS: 2 Input Styles
input{font-family: Arial; font-size: 14px; color: #000000; margin: 1px; padding: 2px; border: 1 solid #CCCCCC}
I want that for the submit buttons and radio buttons, and checkboxes and stuff. But I want input{font-family: Arial; font-size: 14px; color: #000000; margin: 1px; padding: 2px; border: 1 dashed #CCCCCC} for the textboxes... how do I do two? |
|
#3
|
|||
|
|||
|
It's very simple:
input[type="checkbox"]{font-family: Arial; font-size: 14px; color: #000000; margin: 1px; padding: 2px; border: 1 solid #CCCCCC} input[type="submit"]{font-family: Arial; font-size: 14px; color: #000000; margin: 1px; padding: 2px; border: 1 solid #CCCCCC} input[type="text"]{font-family: Arial; font-size: 14px; color: #000000; margin: 1px; padding: 2px; border: 1 dashed #CCCCCC} |
|
#4
|
|||
|
|||
|
Are you sure Tuxie
![]() Doesn't seem to work with IE6, Moz1.0 or NS7 It would be best to use classes anyway because most, probably all, browsers will support them. |
|
#5
|
|||
|
|||
|
It's important to note that Tuxie's example is proper, just that support for it still isn't exactly widespread. So for the mean time, it's a poor solution.
|
|
#6
|
|||
|
|||
|
Tuxie's example works fine the in the following web browers:
Mozilla (Netscape 6+ and other similar browsers) IE5/Mac Opera 5+ (Maybe 6+) and Konqueror (don't know version numbers) |
|
#7
|
|||
|
|||
|
I tested Tuxies example in NS6.1, NS7 (Beta), Moz1.0 and it had no effect.
|
|
#8
|
|||
|
|||
|
Like jkd and MJEggertson said,there's nothing wrong with my code,replace it with something like background-color:red and you will clearly see the input elements become red.
Also,all browsers,except for IE ofcourse,support this. |
|
#9
|
|||
|
|||
|
Quote:
Dosen't work in NS4.7 or Opera6 (identified as Opera or Moz5). |
|
#10
|
|||
|
|||
|
.radio{font-size: 14px; margin: 1px; padding: 1px; border: 0}
.checkbox{font-size: 14px; margin: 1px; padding: 1px; border: 0} .text{font-family: Arial; font-size: 14px; color: #000000; margin: 1px; padding: 2px; border: 1 dashed #CCCCCC} But when I do the classes for each input thingy.. like for the textbox lets say. I would put class="text", and it doesn't work... why the hell not? LOL |
|
#11
|
|||
|
|||
|
Quote:
NS4 doesn't support the W3C standards very well Besides,we are talking about modern browsers,not browsers that are 4 years old.Or would you like to check if it works in Internet Explorer 2?Opera has some quirks in the [attribute=value] thing,because only some attributes work. |
|
#12
|
|||
|
|||
|
lol, but do you guys know my problem?
|
|
#13
|
|||
|
|||
|
oh.... so then, thats the image soruce.. nvm, thanks for the code!
|
![]() |
| Viewing: Dev Shed Forums > Web Design > CSS Help > CSS: 2 Input Styles |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|