Question
· Apr 11, 2019

CSP how to auto refresh with COS

I have a query that I would like to  have refreshing at certain intervals lets say every 30 seconds with out refreshing the page content using the META TAGS

refreshes the whole page but I have a jquery function that will run at those intervals that I can use the problem is getting the jquery to call my COS function or is the way to do it with pure COS

 

<html>
<head>
<!--meta http-equiv="refresh" content="30"-->
<!-- Put your page Title here -->
<title>    Cache Server Page </title>
<script type="text/javascript" src="http://ajax.googleapis.com/ajax/
libs/jquery/1.3.0/jquery.min.js"></script>
<script type="text/javascript">
var auto_refresh = setInterval(
function ()
{
$('#load_tweets').load('#(..myquery())#').fadeIn("slow");
}, 10000); // refresh every 10000 milliseconds </script>
</head><body>
<div id="load_tweets"></div>
<script language="Cache" method="myquery" returntype="%Integer">&sql(select Count(*)INTO:COUNTER from Collection)
QUIT COUNTER
</Script>
</body>
</html>
Discussion (2)1
Log in or sign up to continue