...

View Full Version : make a slider change trigger a routine



eydg
11-01-2012, 05:54 AM
<form name="type"><label >type:</label>
<select name="variant" data-role="slider">
<option value="simple" onchange="trigger()">simple</option>
<option value="complex" onchange="trigger()">complex</option>
</select>
</form>

Normally f.e. with radiobuttons, it is possible to make them trigger a subroutine.

How to achieve that with a slider?

I have tried all the possibilities (although onchance seems the right one), but to no avail.

Pls help.

DanInMa
11-01-2012, 07:27 AM
I am guessing you are referring to a slider created with jquery mobile? If so , you should try to be more specific in the future.

I am not familiar with jquery mobile but this article shows you how to do it : http://www.jonnyreeves.co.uk/2012/listening-for-slide-start-and-slide-stop-events-from-jquery-mobile-1-1-sliders/

eydg
11-01-2012, 06:53 PM
Thanks, you are right, i originated from jquery. this is where i am coming from, at least.

i am a little concerned with compatibility issues across various platforms, though, so i thought about something like this

<form name="type"><label >type:</label>
<select name="variant">
<option value="simple" onchange="trigger()">simple</option>
<option value="complex" onchange="trigger()">complex</option>
</select>
</form>

that's no longer jquery, is it?

Is this function of triggering unimplemented in html5 yet? With other menu elements it works okay.



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum