SitePoint Sponsor

User Tag List

Results 1 to 5 of 5
  1. #1
    SitePoint Zealot
    Join Date
    Dec 2003
    Location
    Ireland
    Posts
    116
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Select Box CSS Properties

    Hi all,

    Can anyone tell me which CSS property I need to edit to remove the white borders around the select box in my picture attached?

    I either need them removed or the same color as the background color in the select box.

    Thanks
    Attached Images Attached Images

  2. #2
    SitePoint Wizard rbutler's Avatar
    Join Date
    Jul 2003
    Location
    Springfield, MO
    Posts
    1,867
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Without a page address, hard to tell exactly, but targeting the background color of a select box should remove that, unless you have padding applied.

    Code:
    form#myForm select{
    background-color:black;
    color:white;
    }
    Ryan Butler

    Midwest Web Design

  3. #3
    SitePoint Zealot
    Join Date
    Dec 2003
    Location
    Ireland
    Posts
    116
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Thanks for the reply,

    Unfortunately I still can't seem to remove the white border, I've tried setting the padding to 0, didn't work.

    My current css is:

    select{
    background-color:#f8d789;
    color:black;
    font-size:11px;
    }

  4. #4
    The CSS Clinic is open silver trophybronze trophy
    Paul O'B's Avatar
    Join Date
    Jan 2003
    Location
    Hampshire UK
    Posts
    40,481
    Mentioned
    182 Post(s)
    Tagged
    6 Thread(s)
    Hi,

    If you are talking about IE then you can't remove that inner white gap at all. IE doesn't allow much styling of the select at all anyway.

    With form elements if you find a style is not being applied then the chances are that the browser concerned doesn't allow that part of the element to be styled.

    See here for more info.

  5. #5
    SitePoint Zealot
    Join Date
    Dec 2003
    Location
    Ireland
    Posts
    116
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    OK Paul, thanks for that.

    Regards
    melt


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •