jQuery run a function every 5 seconds in a jsp page
<p>I have a following script in my jsp page that I need to refresh (call) every 5 seconds to refresh the data to be displayed:</p>

<pre><code>$(document).ready(function () {

            var sampleData = &lt;%=sms.getTimeline()%&gt;;

            ...
        });
</code></pre>

<p>Can someone please let me know how to do so? </p>

<p>Thanks, </p>
