I have a website now and on one of the pages I need to have a table, that loads another website inside of it. I have tried the code below with no luck. The website is not loading up in the table, I also need for it to refresh the website link “url” every 5 minutes.
This is the code I am trying now:
<!DOCTYPE html>
<html>
<head>
<title>Reload iframe demo</title>
<script type=”text/javascript”>
var reloadInterval;
var url=’
var reload_time_in_seconds=5000;
function reloadFrame(id){
document.getElementById(id).src=url;
console.log(“interval triggered”);
}
function initiateInterval(id){
document.getElementById(id).src=url;
reloadInterval=setInterval(“reloadFrame(“+id+”)”,reload_time_in_seconds*5000);
}
</script>
</head>
<body id=”body” onload=”initiateInterval(‘myframe’)”>
<iframe height=”600″ width=”100%” id=”myframe” ></iframe>
</body>
</html>