我是一只咸鱼

导航

循环跳转刷新页面

<%@ page import="net.nw.dao.DefactAllDAO"%>
<%@ page import="java.util.ArrayList"%>
<%@ page import="java.util.List"%>


<html>
<head>
</head>
<body>
<div id="wrapper"></div>
<script type="text/javascript">
//var projectname="UHD-F55KU6300/CH_JAZZ-L";
//var str="http://www.baidu.com";
<% 
    DefactAllDAO dad= new DefactAllDAO();
    List<String> lq= dad.getProjectname_hasdefect();
    System.out.println("lq.get(0).toString():"+lq.get(0).toString());
%>
alert("77777");
var urls=[
"http://localhost/PAS_V1/searchcode_auto.action?projectname=LM-C24F390FHC/CH_SE1279RL",
"http://localhost/PAS_V1/searchcode_auto.action?projectname=LM-C27F390FHC/CH_SE1279RL",
"http://localhost/PAS_V1/searchcode_auto.action?projectname=LM-C32F391FWC/CH_SE1389RDL",
"http://localhost/PAS_V1/searchcode_auto.action?projectname=LM-S19F350HNN/NA_MSTAR",
];

alert("66666");
var i = 0;
function renderFrame(){
    window.setTimeout(function(){ 
        document.getElementById("wrapper").innerHTML = "<iframe src='" + urls[(i++)%urls.length] + "' onload='renderFrame();' width='100%' height='100%'></iframe>";
        i = i % urls.length;}, 5000);
    }
    renderFrame();
</script>
</body>
</html>

 

posted on 2016-03-18 14:13  我是一只咸鱼  阅读(677)  评论(0编辑  收藏  举报