Solved

Styling Select Box Drop Down

Posted on 2013-11-01
2
656 Views
Last Modified: 2013-11-04
I'm trying to figure out how to style this select drop down box like the attached image.  I've got it close, but still can't figure out how to make the vertical line and the smaller black arrows in the image.

Here is my current code and output:
http://jsfiddle.net/gallitin/3xReG/

<style>
select
{
color: #808080;
font-family: myriad-pro-condensed,sans-serif;
font-size: 14px; 
width:150px;
padding:5px;
}
</style>
<select>
    <option>FILTER</option>
</select>

Open in new window

style-select.jpg
0
Comment
Question by:N R
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 53

Expert Comment

by:COBOLdinosaur
ID: 39618053
You can probably do it wit a background image, but I suspect that it will break the control at that point and you will have to use a hack using scripting and an image swap to simulate the control.

If you want to do that kind of a hack you can probably find something already written using Google.  If you are going to re-invent the world there is no need to re-invent the tools to re-invent the wheel.

Trying to turn a select in to some stylistic bauble has more down side then any possible benefit.  You are just going to harm accessibility, usability, reliability with what you are trying to do.

Cd&
0
 
LVL 43

Accepted Solution

by:
Chris Stanyon earned 500 total points
ID: 39618749
Because a <select> element is part of the browser chrome, you won't be able to style it consistently. Normally when you see nicely styled dropdowns like this, the page uses javascript to create something that resembles a drop down. If you look behind the scenes, you'll often find that they're not <select> elements at all - often they'll be buttons, and lists with javacript events wired in to give the impression of a dropdown.
0

Featured Post

Secure Your Active Directory - April 20, 2017

Active Directory plays a critical role in your company’s IT infrastructure and keeping it secure in today’s hacker-infested world is a must.
Microsoft published 300+ pages of guidance, but who has the time, money, and resources to implement? Register now to find an easier way.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Not sure what the best email signature size is? Are you worried about email signature image size? Follow this best practice guide.
Finding original email is quite difficult due to their duplicates. From this article, you will come to know why multiple duplicates of same emails appear and how to delete duplicate emails from Outlook securely and instantly while vital emails remai…
In this tutorial viewers will learn how to style rounded corners for elements in CSS using the border-radius property Begin with a normal styled element such as a div: To style all four corners of the div to be the same degree of roundness, use the …
The viewer will the learn the benefit of plain text editors and code an HTML5 based template for use in further tutorials.

730 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question