The Web Design Group

... Making the Web accessible to all.

Welcome Guest ( Log In | Register )

 
Reply to this topicStart new topic
> Select Tag, How to style select elements
cweb
post Mar 15 2011, 11:24 AM
Post #1





Group: Members
Posts: 9
Joined: 15-March 11
Member No.: 14,134



Hello.
How do you CSS style select elements? This is all new to me so I apologize if I am not using the correct terminology.

Display select elements using absolute positioning w/the top coordinate set to 0pixels & the left coordinate set to 250 pixels. set the font size to 12 pixels.
This is what I have:
CODE
select
          {
        position:absolute;
            top:0px;
                left:250px;
                font-size:12px;
          }

User is offlinePM
Go to the top of the page
Toggle Multi-post QuotingQuote Post
pandy
post Mar 15 2011, 11:28 AM
Post #2


Don't like donuts. Don't do MySpace.
********

Group: WDG Moderators
Posts: 15,368
Joined: 9-August 06
Member No.: 6



So what's wrong with it?


--------------------
"Never go to excess, but let moderation be your guide."
- Cicero

IPB Image
User is offlinePM
Go to the top of the page
Toggle Multi-post QuotingQuote Post
cweb
post Mar 15 2011, 11:45 AM
Post #3





Group: Members
Posts: 9
Joined: 15-March 11
Member No.: 14,134



QUOTE(pandy @ Mar 15 2011, 12:28 PM) *

So what's wrong with it?


I just wanted to know if that was the correct way to set up the select[i] element.
Thanks you
User is offlinePM
Go to the top of the page
Toggle Multi-post QuotingQuote Post
pandy
post Mar 15 2011, 12:29 PM
Post #4


Don't like donuts. Don't do MySpace.
********

Group: WDG Moderators
Posts: 15,368
Joined: 9-August 06
Member No.: 6



You can use the CSS checker to see if your syntax is right and your browsers will show you if it works. wink.gif
http://jigsaw.w3.org/css-validator/validator.html



--------------------
"Never go to excess, but let moderation be your guide."
- Cicero

IPB Image
User is offlinePM
Go to the top of the page
Toggle Multi-post QuotingQuote Post
Frederiek
post Mar 15 2011, 01:07 PM
Post #5


Programming Fanatic
********

Group: Members
Posts: 4,332
Joined: 23-August 06
From: Europe
Member No.: 9



FWIW, in my Safari/Mac, the font-size is still 11px, which apparently is the default size for <select> items. If you set the font-size to an option selector, then it becomes 12px.


--------------------
"The earth does not belong to us. We belong to the earth."
from Vue du ciel (in French)

"Leave scepticism to others and take action"
from HOME by Goodplanet

An inconvenient truth by Al Gore
User is offlinePM
Go to the top of the page
Toggle Multi-post QuotingQuote Post
Darin McGrew
post Mar 15 2011, 03:22 PM
Post #6


WDG Member
********

Group: Root Admin
Posts: 8,008
Joined: 4-August 06
From: Mountain View, CA
Member No.: 3



And FWIW, 12px is smaller than the minimum font size enforced by my browsers, so I'll see the minimum font size instead.


--------------------
Darin McGrew
WDG Member since 1998
User is offlinePM
Go to the top of the page
Toggle Multi-post QuotingQuote Post

Reply to this topicStart new topic
1 User(s) are reading this topic (1 Guests and 0 Anonymous Users)
0 Members:

 



- Lo-Fi Version Time is now: 2nd September 2014 - 06:42 PM