I have problem using custom select(not really a select but a hidden select that is triggered by javascript when click event happens on divs that are styled as i want).
I need to create custom select in search of view. There is no possibility to style option tags(i don't meen in toolset but in general).
So is there a way how to use toolset to create this(use different tags than select and option to create element that will behave as select)?
If not I have already written all needed javascript to hide select and replace it with div's that look like my wanted styled select. When I click on div that represent option I trigger selecting by javascript(...select.selectedIndex = index;...). And there is my problem. I use AJAX for getting new results, but it's not triggered. Could you please tell me why?
I have already tried to to do other javascript approaches, non of them is working(option.selected="selected", select.value="selectedValue"...).
So I would really need to know how to trigger it or if there is a function that I can call directly from my onClick callback.
I cannot send link to my page, I have it on lacalhost for now.
Since you are using AJAX you will need to put your javascript into the callback functions as well.
On your view in the JS editor for the filter section. There should be a button for "Frontend Events" from here you can add the appropriate callback function then add your js code into this.
no this is actually not helping :-/
I have hidden select, so I cannot click on it and so callbacks are not triggered. What I need is trigger ajax call. I thought it would work by setting selectedIndex but it's not. Is there a way to do it?