I have an a link tied to a refresh icon that calls a backend function to reload a section of the page and grab new results to display to the client end.
the function itself works just fine. I now want to automate it in JavaScript to fire off like every 30 seconds.
This is the current link I have:
<a data-ajax="post" data-ajax-callback="PagingCallBack" data-ajax-start="PagingStart" href="@Url.RouteUrl("Engagement", new { controller = "Campaign", action = "PageRefresh", queryID = Model.QueryID, campaignID = Model.CampaignID })" title="Refresh Row">
<img class="rowGrabber" src="/images/actions/refresh.png" height="20" width="20" alt="Refresh Row" title="Refresh Row" />
</a>
how would i take that and set it into a javascript function and call it every 30 seconds or so.
I looked at this response here and it's similar to what I'm looking for I just don't know the call syntax to make it work properly. How to fire AJAX request Periodically?