Changeset 13889 for trunk/FACT++/www/smartfact
- Timestamp:
- 05/25/12 20:21:04 (13 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/FACT++/www/smartfact/index.js
r13886 r13889 249 249 { 250 250 var xmlPage = new XMLHttpRequest(); 251 xmlPage.open('POST', "struct/"+name+'. table', true);251 xmlPage.open('POST', "struct/"+name+'.page', true); 252 252 xmlPage.onload = function () 253 253 { 254 254 if (xmlPage.status!=200) 255 255 { 256 alert("ERROR[0] - HTTP request '"+name+". table': "+xmlPage.statusText+" ["+xmlPage.status+"]");256 alert("ERROR[0] - HTTP request '"+name+".page': "+xmlPage.statusText+" ["+xmlPage.status+"]"); 257 257 //setTimeout("loadPage('+name+')", 5000); 258 258 /****** invalidate ******/ … … 362 362 table.cellPadding = "0px"; 363 363 /*table.width = "100%";*/ 364 //table.setAttribute("style", "overflow:hidden;position:fixed;top:0px;left:"+window.innerWidth+"px;") ;364 //table.setAttribute("style", "overflow:hidden;position:fixed;top:0px;left:"+window.innerWidth+"px;") 365 365 table.setAttribute("style", "position:absolute;top:0px;left:"+window.innerWidth+"px;width:100%;"); 366 366 … … 547 547 fdivH.setAttribute("class", "icon_color"); 548 548 fdivH.setAttribute("style", "background-position:-408px -57px;"); 549 //fdivH.setAttribute("style", "background-position:-13px -57px;"); 549 550 } 550 551 else … … 572 573 $("body").appendChild(table); 573 574 575 for (var i=0; i<lines.length; i++) 576 { 577 lines[i] = trim(lines[i]); 578 if (lines[i][0] == '#') 579 lines.splice(i--, 1); 580 } 581 582 // Concatenate consecutive lines until they have at least two colons 583 for (var i=2; i<lines.length; i++) 584 { 585 if (lines[i].length==0) 586 continue; 587 588 while (i<lines.length) 589 { 590 var cols = lines[i-1].split('|'); 591 if (cols.length>=3) 592 break; 593 594 lines[i-1] += lines[i].length==0 ? '<p/>' : " "+lines[i]; 595 lines.splice(i,1); 596 } 597 } 598 574 599 var counter = 1; 575 600 for (var i=1; i<lines.length; i++) 576 601 { 577 lines[i] = trim(lines[i]); 578 579 if (lines[i].length==0 || lines[i][0] == '#') 602 if (lines[i].length==0) 580 603 continue; 581 604 582 var cols = lines[i].split(' :');605 var cols = lines[i].split('|'); 583 606 if (cols.length != 3 && cols.length !=4) 584 607 { … … 639 662 var img = $new("img"); 640 663 img.style.width="100%"; 641 img.src = check[1]; 664 img.style.display="block"; 665 img.src = "img/"+check[1]; 642 666 td0.style.paddingLeft=0; 643 667 td0.style.border=0; … … 965 989 966 990 var xmlText = new XMLHttpRequest(); 967 xmlText.open('POST', "data/"+fname+'. txt', true);991 xmlText.open('POST', "data/"+fname+'.data', true); 968 992 xmlText.onload = function () 969 993 { 970 994 if (xmlText.status!=200) 971 995 { 972 alert("ERROR[1] - HTTP request '"+fname+". txt': "+xmlText.statusText+" ["+xmlText.status+"]");996 alert("ERROR[1] - HTTP request '"+fname+".data': "+xmlText.statusText+" ["+xmlText.status+"]"); 973 997 timeoutText = setTimeout(refresh_text, 10000); 974 998 return;
Note:
See TracChangeset
for help on using the changeset viewer.