WEB开发网
开发学院网页设计JavaScript js解析json并生成html页面 阅读

js解析json并生成html页面

 2012-10-25 16:08:14 来源:WEB开发网   
核心提示:newW.document.write("for(var i=0;i<issueList.length;i++){");newW.document.write("var issues = issueList[i].issues;");newW.document.write(
newW.document.write("for(var i=0;i<issueList.length;i++){");
newW.document.write("var issues = issueList[i].issues;");
newW.document.write("for (var j =0; j< issues.length; j++){");
newW.document.write("if(date == issues[j].t){");
newW.document.write("if(\"ck\"==value){ var Eurl = \"http://localhost:8080/xww/staticpage/\"+issues[j].d.substring(3)+\"my_images/AA_1_new_static.jpg\";");
newW.document.write("document.getElementById('img').src=Eurl;");
newW.document.write("}");
newW.document.write("if(\"open\"==value){");
newW.document.write("window.open(\"http://localhost:8080/xww/staticpage/\"+issues[j].d.substring(3)+\"edition_1.html\");");
newW.document.write("}}}}}};");


newW.document.write("function test() { alert('test"+issueList.length+"');}");
newW.document.write("</SCRIPT>");
//document.write(" <SCRIPT language=Javascript src=\"js/issue.js\" charset='utf-8'><\/script>");
//document.write("<SCRIPT language=Javascript src=\"js/edition.js\" charset='utf-8'><\/script>");
newW.document.write("<title>版图</title>");
newW.document.write("</head>");
newW.document.write("<body >");
newW.document.write("<body onload=\"load_issue();\">");
newW.document.write("<div class=\"div_center\"> ");
newW.document.write("<!--左侧版面图部分-->");
newW.document.write("<div class=\"left_c\"><div class=\"ban1\"><div><img src=\"staticpage/222220110930/my_images/首都食品安全报_1_new_static.jpg\" usemap=\"#PagePicMap\" border=\"0\" height=\"575\" width=\"400\" id=\"img\"></div></div></div>");
newW.document.write("<!--右侧目录部分-->");
newW.document.write("<div class=\"right_c1\">");
newW.document.write("<h2>健康导报</h2>");
newW.document.write("<p class=\"jj\"><select id=\"y\" name=\"y\"><option value=\"0\">---年---</option></select></p>");
newW.document.write("<p class=\"jj\">");
newW.document.write("<select id=\"m\" name=\"m\" onchange=\"Mchange(this.value)\"><option value=\"0\">---月---</option></select>");
newW.document.write("<select id=\"d\" name=\"d\" onchange=\"Dchange('ck');\"><option value=\"0\">---日---</option></select>");

上一页  1 2 3 4  下一页

Tags:js 解析 json

编辑录入:爽爽 [复制链接] [打 印]
赞助商链接