2 different decorated seletc'and in the form that do not alter the design of a standard

The question was asked: 49 years 9 months ago   views: 8

Good day gentlemen

Can anyone give an example of 2 different selects v the clearance does not concern them select a standard, and was replaced by the arrow of the select picture?

p.s. To fix all selects again - no problem. To find a script that would change oformlenie it doesn't matter. 2 different select, do not alter the design of a standard, I have a problems I went and with css and js, though it seemed simple

Asked: 01-01-1970 в 03:00:00
Don't understand in what could be the problem :( Assign different selectam different classes. Styles write for classes, not tags. Change classes by changing the appearance of the select and not touching a standard select, without the class. different classes - different design. At least 100 500 designs in one form... - 16-01-2013 в 13:22:12
Yes so it is true, if you change a class, only css properties. Here if to try to replace the js arrow from select points will all go to go. It would be so easy I wouldn't have asked - 16-01-2013 в 13:25:34
prezhdnemu at a loss... what is stopping the JavaScript to change the arrow selectam only to those who have the appropriate class? - 16-01-2013 в 14:03:14
Dear, I'm not guru in JS but nonetheless failed to replace the script have 2 different selects s on one form, do not change the design from others. If it's something basic, please, scare code. Take the same example from @lampa - surprisingly easier that I used, but strangely works for one select (which is sad). If it was pure css everything would be just - 16-01-2013 в 14:22:15

Answers   1


As always present your select, once made as an example for @heidel:

Your select html javascript css:

See the line that specifies the class:

var select_menu = $('<ul />', { class: 'menu' }).insertAfter(select_wrap);

Model on:

var select_menu = $('<ul />', { class: $this.attr('data_class') }...

And the select attribute:

<select name='1234' data_class='first_class'> <option value='1'>first</option> <option value='2'>second</option> <option value='3'>third</option> <option value='4'>fourth</option> </select>

So it is possible for each select to set your class.

Answered: 16-01-2013 в 13:26:57
Did everything exactly (Even tried to test it online on jsbin). Code in the form in the link really changes the design of the select but all in fixed form, it just standard. jsbin.com/itojof/1/edit actually, with all seemingly simple topics with simple select deal from last week - 16-01-2013 в 13:51:35