This goal is to create a script thats can be used with multiple dropdowns on the same page. The dropdowns content is various (pics, lists etc) so this topic will only focus on the dropdowns basics (open/close/style).
I build the dropdowns by using three divs and two different style-classes that toggle (depending on if the dropdown is open or not).
I am in the middle of the process of figuring out how to make only one div show at once, so if one dropdown is open and some other dropdown is clicked, the first thats opened should automaticly close (hide). I am total beginner in jQuery so all help is very appreciated, it would be great if you could leave a comment in the code so I get it and learn some.
This is how the code looks for now. I modify a script I got help with earlier.
Later the dropdown also need a special function that I hope is possible to do in jQuery. When close the dropdown (I havent really made it so far yet) there should be two different options how to do it:
1: Click at label or outside the div (at the page), used when there is multiple settings in the dropdown so many clicks can be made in the dropdown before close. 2: Click at label, inside or outside the div (when div workes like a selectbox).
Sorry for bad english.