- This topic is empty.
-
AuthorPosts
-
June 20, 2009 at 4:05 am #25214
Frodo64
MemberAnyone know any efficient way how to style from <select> tags? I mean completely: add background image and style <option> values? I’m looking for cross browser technique. Maybe anyone did it and can share the knowledge?
June 20, 2009 at 5:36 am #59381apostrophe
ParticipantIt can’t be done with css alone. Check out this jQuery plugin http://www.scottdarby.com/2009/05/jquery-plugin-stylish-select-unobstrusive-select-box-replacement/
June 20, 2009 at 8:09 am #59382Frodo64
MemberThanks! I will try to use it right now :)
June 20, 2009 at 10:21 am #59399Frodo64
Member"apostrophe" wrote:It can’t be done with css alone. Check out this jQuery plugin http://www.scottdarby.com/2009/05/jquery-plugin-stylish-select-unobstrusive-select-box-replacement/It is wokring fine on Firefox, but it’s buggy in IE6, IE7. Maybe I’m doing something wrong?
[attachment=0]wrong.jpg[/attachment]
The css of this select:
Code:ul.newList {margin:0; padding:0; list-style:none; color:#666; width:160px; background:#feffff; position:absolute; display:none; border:1px solid #666; top:22px; left:0; overflow:auto; z-index:9999;}
.newListSelected {width:150px; color:#666; height:18px; padding:4px 0 0 12px; float:left; background:url(images/search-select-bg.gif) no-repeat; outline:none;}
.newListSelected span {width:162px; display:block;}
ul.newList li {padding:3px 12px;}
.selectedTxt {width:127px; overflow:hidden; height:16px; padding:0 23px 0 0;}
.hiLite {background:#23788B!important; color:#feffff!important;}
.newListHover {background:#ccc!important; color:#000!important; cursor:default;}
.newListSelHover {cursor:default;}
.newListOptionTitle {font-weight:bold;}
.newListOptionTitle ul {margin:3px 0 0;}
.newListOptionTitle li {font-weight:normal; border-left:1px solid #666;}The link: LINK DELETED
June 20, 2009 at 12:17 pm #59402Frodo64
MemberAfter testing like 6 other jquery plugins I came back to this one. The whole thing about ie’s was the z-index property..
June 20, 2009 at 12:30 pm #59400apostrophe
ParticipantSo it’s working now? I confess I’ve never used the plugin. When it comes to forms, if it can’t be done with css alone then I don’t bother. I’d rather lose a little style and keep the functionality and accessibility.
If you can’t solve the z-index issue I would suggest contacting the plugin author who claims that it works in all browsers from ie6 up.June 21, 2009 at 12:33 pm #59427Frodo64
MemberYes it is working right now. Thanks for nice plugin link :)
-
AuthorPosts
- The forum ‘CSS’ is closed to new topics and replies.