This is probably something quite easy to resolve, however, I am having some difficulties finding out the correct answer.
Essentially, I have a jQuery slider that I am using. Each time the slider is changed, I would like to update a <span>, based on the changing of a <select> box.
To see the code in action, please visit http://jsbin.com/etusu/edit
As you will see, the <select> box updates fine with each slide, but the <span> updates only once. I would like the to update just as often as the <select>, because eventually, I will hide the <select> box. Any help on this would be greatly appreciated.
You’re fetching the time text only once, here:
and using that variable to set the text:
Instead you need to fetch the value every time, since the
:selectedoption changes (and that original variable won’t update), like thisHere’s the updated/working version.