Hi all,

I'm trying to add spacing between the <option> tags by padding, height and margin - yet none have worked. Does anyone have any ideas? It's the simple things that stop me in my tracks haha. All of the options look cramped up and untidy, I'd like to give them room to breathe :)

M

Recommended Answers

All 2 Replies

Styling is not really an option (no punn intended) for the option element. Except for background-color and color I beleive..., style settings applied for the option element are ignored.

Similar discussion recently..
http://www.daniweb.com/web-development/web-design-html-and-css/threads/464295/how-to-define-the-font-for-selected-option-in-dropdown

commented: I've only read up to the pun yet here's a plus 1. No rhyme intended. ;) +4

Sorry for missing the recent discussion.

That sucks, I've seen so many funky dropdowns though where there is more spacing, different font sizes, bold options that aren't indented and so on. AFter a little more research it appears that they can't be stryled because they are complied by the browser and not HTML. The only way around this is to use a plugin that complies its own dropdows such as:

http://labs.abeautifulsite.net/jquery-dropdown/

That can be styled and it's being built from lots of components by JQuery.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.