Index: trunk/FACT++/www/smartfact/index.js
===================================================================
--- trunk/FACT++/www/smartfact/index.js	(revision 13888)
+++ trunk/FACT++/www/smartfact/index.js	(revision 13889)
@@ -249,10 +249,10 @@
 {
     var xmlPage = new XMLHttpRequest();
-    xmlPage.open('POST', "struct/"+name+'.table', true);
+    xmlPage.open('POST', "struct/"+name+'.page', true);
     xmlPage.onload = function ()
     {
         if (xmlPage.status!=200)
         {
-            alert("ERROR[0] - HTTP request '"+name+".table': "+xmlPage.statusText+" ["+xmlPage.status+"]");
+            alert("ERROR[0] - HTTP request '"+name+".page': "+xmlPage.statusText+" ["+xmlPage.status+"]");
             //setTimeout("loadPage('+name+')", 5000);
             /****** invalidate ******/
@@ -362,5 +362,5 @@
     table.cellPadding = "0px";
     /*table.width = "100%";*/
-    //table.setAttribute("style", "overflow:hidden;position:fixed;top:0px;left:"+window.innerWidth+"px;");
+    //table.setAttribute("style", "overflow:hidden;position:fixed;top:0px;left:"+window.innerWidth+"px;")
     table.setAttribute("style", "position:absolute;top:0px;left:"+window.innerWidth+"px;width:100%;");
 
@@ -547,4 +547,5 @@
         fdivH.setAttribute("class", "icon_color");
         fdivH.setAttribute("style", "background-position:-408px -57px;");
+        //fdivH.setAttribute("style", "background-position:-13px -57px;");
     }
     else
@@ -572,13 +573,35 @@
     $("body").appendChild(table);
 
+    for (var i=0; i<lines.length; i++)
+    {
+        lines[i] = trim(lines[i]);
+        if (lines[i][0] == '#')
+            lines.splice(i--, 1);
+    }
+
+    // Concatenate consecutive lines until they have at least two colons
+    for (var i=2; i<lines.length; i++)
+    {
+        if (lines[i].length==0)
+            continue;
+
+        while (i<lines.length)
+        {
+            var cols = lines[i-1].split('|');
+            if (cols.length>=3)
+                break;
+
+            lines[i-1] += lines[i].length==0 ? '<p/>' : " "+lines[i];
+            lines.splice(i,1);
+        }
+    }
+
     var counter = 1;
     for (var i=1; i<lines.length; i++)
     {
-        lines[i] = trim(lines[i]);
-
-        if (lines[i].length==0 || lines[i][0] == '#')
+        if (lines[i].length==0)
             continue;
 
-        var cols = lines[i].split(':');
+        var cols = lines[i].split('|');
         if (cols.length != 3 && cols.length !=4)
         {
@@ -639,5 +662,6 @@
             var img = $new("img");
             img.style.width="100%";
-            img.src = check[1];
+            img.style.display="block";
+            img.src = "img/"+check[1];
             td0.style.paddingLeft=0;
             td0.style.border=0;
@@ -965,10 +989,10 @@
 
     var xmlText = new XMLHttpRequest();
-    xmlText.open('POST', "data/"+fname+'.txt', true);
+    xmlText.open('POST', "data/"+fname+'.data', true);
     xmlText.onload = function ()
     {
         if (xmlText.status!=200)
         {
-            alert("ERROR[1] - HTTP request '"+fname+".txt': "+xmlText.statusText+" ["+xmlText.status+"]");
+            alert("ERROR[1] - HTTP request '"+fname+".data': "+xmlText.statusText+" ["+xmlText.status+"]");
             timeoutText = setTimeout(refresh_text, 10000);
             return;
