X-Git-Url: http://matita.cs.unibo.it/gitweb/?a=blobdiff_plain;f=helm%2Fon-line%2Fjavascript%2Fcontrol.js;h=fbc08f3f9b692e38f3fd33c53992cb3fa308b93d;hb=3924d3a11a488176c28af5e82ee3810d9a6350ed;hp=de22891cc09b3fc74d4fa2c11b17448bfe30116a;hpb=a3e1fdeba3b71604dc8adaa3c06e4cece00ea1c9;p=helm.git diff --git a/helm/on-line/javascript/control.js b/helm/on-line/javascript/control.js index de22891cc..fbc08f3f9 100644 --- a/helm/on-line/javascript/control.js +++ b/helm/on-line/javascript/control.js @@ -103,6 +103,12 @@ function refreshtheoryHeader(headerURL) return true; } +function getCICMathMLKeys() +{ + //Important note: do not modify this function without modifying makeURL + return escape("C1,C2,L"); +} + function makeURL(type,uri,cicflags,typesflags) { var mode = top.mode; @@ -113,7 +119,8 @@ function makeURL(type,uri,cicflags,typesflags) var keys = ""; var url = ""; - var interfaceURL = chopSlash(chopSlash(top.topurl)) + "/cic/index.html"; + var interfaceURL = chopSlash(chopSlash(top.topurl)) + + ((type == "cic") ? "/cic/index.html" : "/theory/index.html"); var output = mode_list[0]; var format; @@ -128,6 +135,8 @@ function makeURL(type,uri,cicflags,typesflags) "&patch_dtd=" + mode_list[6]; } else { if (format == "html" && type == "cic") { + //Important note: do not modify this function without modifying + //getCICMathMLKeys keys = escape("C1,HC2,L")+"¶m.processorURL=" + escape(processorURL) + "¶m.getterURL=" + escape(getterURL) + "&prop.doctype-public="+escape("-//W3C//DTD XHTML 1.0 Transitional//EN")+ @@ -183,6 +192,9 @@ function makeURL(type,uri,cicflags,typesflags) url = processorURL + "apply?xmluri=" + escape(getterURL + "getxml?uri=" + uri) + "&keys=" + keys + "¶m.CICURI=" + uri + "¶m.naturalLanguage=" + naturalLanguage + "¶m.annotations=" + annotations; } - return interfaceURL + "?url=" + escape(url); + if (output == "raw") + return url + else + return interfaceURL + "?url=" + escape(url); }