]> matita.cs.unibo.it Git - helm.git/commitdiff
Now the on-line interface can use a Getter and an UWOBO on any machine
authorClaudio Sacerdoti Coen <claudio.sacerdoticoen@unibo.it>
Wed, 7 Mar 2001 17:02:42 +0000 (17:02 +0000)
committerClaudio Sacerdoti Coen <claudio.sacerdoticoen@unibo.it>
Wed, 7 Mar 2001 17:02:42 +0000 (17:02 +0000)
helm/cgi/mkcontrol.pl
helm/cgi/mkindex.pl
helm/cgi/mkindexcic.pl
helm/cgi/mkindextheory.pl

index 96c5c952274d3f9862a15bc9a300d14a807c78bc..5acadae5695e85e750ee78133916208cbe5510c3 100755 (executable)
@@ -21,6 +21,8 @@ $mode = $cgi->param('mode');
 $cicuri = $cgi->param('cicuri');
 $theoryuri = $cgi->param('theoryuri');
 $topurl = $cgi->param('topurl');
+$processorURL = $cgi->param('processorURL');
+$getterURL = $cgi->param('getterURL');
 ($mode1,$mode2,$mode3,$mode4,$mode5) = split(/,/, $mode);
 $natural = "checked" if ($mode4 eq "yes");
 $annotations = "checked" if ($mode5 eq "yes");
@@ -77,8 +79,10 @@ print <<EOT;
       </select>
     </td>
     <td>
-     <a target="_top" href="$topurl?mode=$mode&cicuri=$cicuri&theoryuri=$theoryuri">Reload</a><br>
+     <a target="_top" href="$topurl?mode=$mode&cicuri=$cicuri&theoryuri=$theoryuri&processorURL=$processorURL&getterURL=$getterURL">Reload</a><br>
      (do it also before attempting to take a link to the current page)
+     <input type="hidden" name="hiddenprocessorURL" value="$processorURL">
+     <input type="hidden" name="hiddengetterURL" value="$getterURL">
      <input type="hidden" name="hiddentopurl" value="$topurl">
      <input type="hidden" name="hiddenmode" value="$mode">
      <input type="hidden" name="hiddencicuri" value="$cicuri">
@@ -90,6 +94,9 @@ print <<EOT;
       <input type="checkbox" $natural onClick="updateNatural(this)">&nbsp;Natural Language</input>
       <input type="checkbox" $annotations onClick="updateAnnotations(this)">&nbsp;Annotations</input>
     </td>
+    <td>
+     <a target="_top" href="../html/index.html?mode=$mode&cicuri=$cicuri&theoryuri=$theoryuri&processorURL=$processorURL&getterURL=$getterURL">Configuration panel</a>
+    </td>
   </tr>
 </table>
 </form>
index cd6e47d61d267a77cdb359fcd077cbdc44bc0ddf..955d6d8b0e6dd597fc832d190da129d574bab783 100755 (executable)
@@ -22,6 +22,8 @@ $cgi = new CGI($ENV{"REQUEST_URL"});
 $mode      = $cgi->param('mode');
 $cicuri    = $cgi->param('cicuri');
 $theoryuri = $cgi->param('theoryuri');
+$processorURL = $cgi->param('processorURL');
+$getterURL = $cgi->param('getterURL');
 $topurl    = $cgi->url();
 
 print <<EOT;
@@ -34,15 +36,15 @@ Content-type: text/html
  <title>Index of $cicuri and $theoryuri</title>
 </head>
 <frameset rows="18%,*" border="0" scrolling="no">
-  <frame src="mkcontrol.pl?topurl=$topurl&mode=$mode&cicuri=$cicuri&theoryuri=$theoryuri" name="control"/>
+  <frame src="mkcontrol.pl?topurl=$topurl&mode=$mode&cicuri=$cicuri&theoryuri=$theoryuri&processorURL=$processorURL&getterURL=$getterURL" name="control"/>
   <frameset cols="50%,50%" border="0" scrolling="no">
      <frameset rows="11%,*" border="0" scrolling="no">
         <frame src="mkheader.pl?uri=$theoryuri" name="theoryheader"/>
-        <frame src="mkindextheory.pl?theoryuri=$theoryuri" name="theoryresult"/>
+        <frame src="mkindextheory.pl?theoryuri=$theoryuri&getterURL=$getterURL" name="theoryresult"/>
      </frameset>
      <frameset rows="11%,*" border="0" scrolling="no">
         <frame src="mkheader.pl?uri=$cicuri" name="cicheader"/>
-        <frame src="mkindexcic.pl?cicuri=$cicuri" name="cicresult"/>
+        <frame src="mkindexcic.pl?cicuri=$cicuri&getterURL=$getterURL" name="cicresult"/>
      </frameset>
   </frameset>
 </frameset>
index e592b057962b4870245d7665436dcb69070a7d8c..6e0a566b1264ee3f2ffc779230397075d2e03ab8 100755 (executable)
@@ -20,13 +20,14 @@ use CGI;
 
 my $cgi = new CGI($ENV{"REQUEST_URL"});
 $uri = $cgi->param('cicuri');
+$getterURL = $cgi->param('getterURL');
 $uri =~ s/(.*)\/$/$1/; # Remove a final slash if present
 $uri .= "/"; # Put a final slash
 $myurl = $cgi->url();
 
 $cont = ""; # modified by side-effect by &callback
 my $ua = LWP::UserAgent->new;
-my $request = HTTP::Request->new(GET => $getter_url."ls?format=txt&baseuri=".$uri);
+my $request = HTTP::Request->new(GET => $getterURL."ls?format=txt&baseuri=".$uri);
 my $response = $ua->request($request, \&callback);
  
 @filenames = split(/\n/, $cont);
@@ -38,7 +39,7 @@ if ($uri ne "cic:/") {
  $output = <<EOT;
 <tr>
 <td><img border="0" src="/icons/back.gif" alt="[BACK]"></td>
-<td><a href="$myurl" onClick="top.frames[0].document.forms[0].hiddencicuri.value='$uridotdot'; refreshReload(); refreshCICHeader(); this.search='?cicuri=$uridotdot';" onMouseOver="window.status='$uridotdot'; return true">Parent Directory</a></td>
+<td><a href="$myurl" onClick="top.frames[0].document.forms[0].hiddencicuri.value='$uridotdot'; refreshReload(); refreshCICHeader(); this.search='?cicuri=$uridotdot&getterURL=$getterURL';" onMouseOver="window.status='$uridotdot'; return true">Parent Directory</a></td>
 </tr>
 EOT
 }
@@ -52,7 +53,7 @@ foreach $i (@filenames) {
       $output .= <<EOT;
 <tr>
 <td><img border="0" src="/icons/folder.gif" alt="[DIR]"></td>
-<td><a href="$myurl" onClick="top.frames[0].document.forms[0].hiddencicuri.value='$uri$name'; refreshReload(); refreshCICHeader(); this.search='?cicuri=$uri$name';" onMouseOver="window.status='$uri$name'; return true">$name</a></td>
+<td><a href="$myurl" onClick="top.frames[0].document.forms[0].hiddencicuri.value='$uri$name'; refreshReload(); refreshCICHeader(); this.search='?cicuri=$uri$name&getterURL=$getterURL';" onMouseOver="window.status='$uri$name'; return true">$name</a></td>
 </tr>
 </tr>
 EOT
@@ -62,7 +63,7 @@ EOT
             $output .= <<EOT;
 <tr>
 <td><img border="0" src="/icons/generic.red.gif" alt="[DIR]"></td>
-<td><a href="" target="cic" onClick="this.href=makeURL('cic','$uri$name','$processor_url','$getter_url','$flagscic','$flagstypes')" onMouseOver="window.status='$uri$name'; return true">$name</a>
+<td><a href="" target="cic" onClick="this.href=makeURL('cic','$uri$name','$flagscic','$flagstypes')" onMouseOver="window.status='$uri$name'; return true">$name</a>
 </tr>
 EOT
          } else {
index b92f363611f6437db70f20e4eeb12ad84fe6e3cd..c92321f123e8d5b08962e917adfea6182e20ab71 100755 (executable)
@@ -20,13 +20,14 @@ use CGI;
 
 my $cgi = new CGI($ENV{"REQUEST_URL"});
 $uri = $cgi->param('theoryuri');
+$getterURL = $cgi->param('getterURL');
 $uri =~ s/(.*)\/$/$1/; # Remove a final slash if present
 $uri .= "/"; # Put a final slash
 $myurl = $cgi->url();
 
 $cont = ""; # modified by side-effect by &callback
 my $ua = LWP::UserAgent->new;
-my $request = HTTP::Request->new(GET => $getter_url."ls?format=txt&baseuri=".$uri);
+my $request = HTTP::Request->new(GET => $getterURL."ls?format=txt&baseuri=".$uri);
 my $response = $ua->request($request, \&callback);
  
 @filenames = split(/\n/, $cont);
@@ -38,7 +39,7 @@ if ($uri ne "theory:/") {
  $output = <<EOT;
 <tr>
 <td><img border="0" src="/icons/back.gif" alt="[BACK]"></td>
-<td><a href="$myurl" onClick="top.frames[0].document.forms[0].hiddentheoryuri.value='$uridotdot'; refreshReload(); refreshTheoryHeader(); this.search='?theoryuri=$uridotdot';" onMouseOver="window.status='$uridotdot'; return true">Parent Directory</a></td>
+<td><a href="$myurl" onClick="top.frames[0].document.forms[0].hiddentheoryuri.value='$uridotdot'; refreshReload(); refreshTheoryHeader(); this.search='?theoryuri=$uridotdot&getterURL=$getterURL';" onMouseOver="window.status='$uridotdot'; return true">Parent Directory</a></td>
 </tr>
 EOT
 }
@@ -52,7 +53,7 @@ foreach $i (@filenames) {
       $output .= <<EOT;
 <tr>
 <td><img border="0" src="/icons/folder.gif" alt="[DIR]"></td>
-<td><a href="$myurl" onClick="top.frames[0].document.forms[0].hiddentheoryuri.value='$uri$name'; refreshReload(); refreshTheoryHeader(); this.search='?theoryuri=$uri$name';" onMouseOver="window.status='$uri$name'; return true">$name</a></td>
+<td><a href="$myurl" onClick="top.frames[0].document.forms[0].hiddentheoryuri.value='$uri$name'; refreshReload(); refreshTheoryHeader(); this.search='?theoryuri=$uri$name&getterURL=$getterURL';" onMouseOver="window.status='$uri$name'; return true">$name</a></td>
 </tr>
 EOT
    } elsif ($type eq "object") {
@@ -61,7 +62,7 @@ EOT
            $output .= <<EOT;
 <tr>
 <td><img border="0" src="/icons/generic.red.gif" alt="[DIR]"></td>
-<td><a href="" target="theory" onClick="this.href=makeURL('theory','$uri$name','$processor_url','$getter_url','$flagscic','$flagstypes')" onMouseOver="window.status='$uri$name'; return true">$name</a>
+<td><a href="" target="theory" onClick="this.href=makeURL('theory','$uri$name','$flagscic','$flagstypes')" onMouseOver="window.status='$uri$name'; return true">$name</a>
 </tr>
 EOT
          } else {