I am attempting to query a db row every n seconds to see if a value has changed, then based that value I want to build a class that I can apply to a div in my page.
I can currently echo out the slide number, i have this
echo("The current slide number is: ".$currentSlideNbr);
but am not sure how to query every n seconds and then add .$currentSlideNbr to my class name with jquery
Thanks in advance
here’s a simple javascript example that will trigger every n second(s)
if you want to stop the process at any time you can do
not that
datashould only contain the classname you like to add. So notbut