Hullo there. This script below is being called onload of my page using the following code...
My problem is that it only semi works. If I remove the url = url + '?BogusVariable=' + new Date; line then if I refresh the page that the sql query is on, it will then update. But I was told by Bokeh in the PHP forum that this was a caching issue and to append th date onto the url as a variable. This then stops the script from working all together. I have been through countless examples but nowhere seems to have an example of what I'm trying to do. Can anyone help me get a working example?HTML Code:<body onload="javascript:testit('testdiv','/ajax.php')">
http://gramac4.freeserverhost.com/test.php si the link
Code:<script type="text/javascript"> testit = function (id,url){ url = url + '?BogusVariable=' + new Date; new Ajax.PeriodicalUpdater(id, url, { method: 'get', frequency: 1, asynchronous: true, insertion: Element.update, decay: 2 }); } </script>


Reply With Quote
Bookmarks