Diff for /loncom/html/res/adm/pages/menu.html between versions 1.65 and 1.72

version 1.65, 2002/08/11 18:38:07 version 1.72, 2002/10/25 14:04:42
Line 45  var statustop = ''; Line 45  var statustop = '';
 var statusbot = '';  var statusbot = '';
 var active = 0;  var active = 0;
 var dislocked = 1;  var dislocked = 1;
   var statuslocked = 0;
   
 var imgpath='/res/adm/pages/';  var imgpath='/res/adm/pages/';
 var fontpath='/adm/lonLCDfont/';  var fontpath='/adm/lonLCDfont/';
 var currentURL='';  var currentURL='';
 var reloadURL='';  var reloadURL='';
   var currentSymb='';
   var reloadSymb='';
 var currentStale=1;  var currentStale=1;
 var menucltim;  var menucltim;
   
Line 95  function syncclock(servertime) { Line 98  function syncclock(servertime) {
 function advanceclock() {  function advanceclock() {
     var clock=new Date();      var clock=new Date();
     clock.setTime(clock.getTime()+clockdelta);      clock.setTime(clock.getTime()+clockdelta);
       if (!statuslocked) {
          var days=""+clock.getDate();
          if (days.length<2) { days="0"+days; }
          var mons=""+(clock.getMonth()+1);
          if (mons.length<2) { mons="0"+mons; }
          var years=""+clock.getYear();
   
          if (years>1000) {
             years=years.substring(2,4);
          } else {
             years=years.substring(1,3);
          }
          statustop=mons+'/'+days+'/'+years;
   
          var secs=""+clock.getSeconds();
          if (secs.length<2) { secs="0"+secs; }
          var mins=""+clock.getMinutes();
          if (mins.length<2) { mins="0"+mins; }
          var hours=""+clock.getHours();
          if (hours.length<2) { hours=" "+hours; }
          statusbot=hours+':'+mins+':'+secs;
   
     var days=""+clock.getDate();         if (!dislocked) { showdisplay(); }
     if (days.length<2) { days="0"+days; }  
     var mons=""+(clock.getMonth()+1);  
     if (mons.length<2) { mons="0"+mons; }  
     var years=""+clock.getYear();  
   
     if (years>1000) {  
        years=years.substring(2,4);  
     } else {  
        years=years.substring(1,3);  
     }      }
     statustop=mons+'/'+days+'/'+years;  
   
     var secs=""+clock.getSeconds();  
     if (secs.length<2) { secs="0"+secs; }  
     var mins=""+clock.getMinutes();  
     if (mins.length<2) { mins="0"+mins; }  
     var hours=""+clock.getHours();  
     if (hours.length<2) { hours=" "+hours; }  
     statusbot=hours+':'+mins+':'+secs;  
   
     if (!dislocked) { showdisplay(); }  
   
     setTimeout('advanceclock();',1000);      setTimeout('advanceclock();',1000);
 }  }
   
Line 225  function clearbut(row,col) { Line 228  function clearbut(row,col) {
 }  }
   
 function setstatus(tp,bt) {  function setstatus(tp,bt) {
    this.document['led'].src="ledblink.gif";     this.document['led'].src="http://"+clienthost+imgpath+"ledblink.gif";
    statustop=tp;     statustop=tp;
    statusbot=bt;     statusbot=bt;
      statuslocked=1;
    defdis();     defdis();
    endsend();  
 }  }
   
 function is_editable_resource (url) {  function is_editable_resource (url) {
   // figure out if this a specific resource version
    var Chunks = url.split('.');     var Chunks = url.split('.');
    var tmp = Chunks[Chunks.length-1];     var tmp = Chunks[Chunks.length-1];
    if ((Chunks.length > 1) && (Math.floor(tmp) == tmp)) {     if ((Chunks.length > 1) && (Math.floor(tmp) == tmp)) {
        return true;         return false;
    }      }
    return false;  // see if this is actually in resource space
      var SlashChunks=url.split('/');
      if (SlashChunks[1]!='res') { return false; } 
      return true;
 }  }
   
 function cstrgo(currenturl,defaulturl) {  function cstrgo(currenturl,defaulturl) {
Line 249  function cstrgo(currenturl,defaulturl) { Line 256  function cstrgo(currenturl,defaulturl) {
        (! is_editable_resource(currenturl))) {         (! is_editable_resource(currenturl))) {
       url = defaulturl;        url = defaulturl;
    } else {     } else {
       url = currenturl;        var SlashChunks=currenturl.split('/');
       var res_pattern     = /^\/res\/[A-z0-p]+\//;        SlashChunks[1]='priv';
       if (res_pattern.test(url)) {        var i;
          // map /res/103/turtle to /priv/turtle        for (i=2;i<SlashChunks.length;i++) {
          url = url.replace(/^\/res\/[A-z0-9]+\//,'/priv/');            SlashChunks[i]=SlashChunks[i+1];
       } else {  
          url = defaulturl;  
       }        }
         SlashChunks.length--;
         url=SlashChunks.join('/');
    }     }
    this.document['led'].src="ledsend.gif";     this.document['led'].src="ledsend.gif";
    if (url != '') {     if (url != '') {
Line 266  function cstrgo(currenturl,defaulturl) { Line 273  function cstrgo(currenturl,defaulturl) {
   
 function go(url) {  function go(url) {
    windowcheck();     windowcheck();
      statuslocked=0;
    this.document['led'].src="ledsend.gif";     this.document['led'].src="ledsend.gif";
    if (url!='' && url!= null) {     if (url!='' && url!= null) {
        currentURL = null;         currentURL = null;
          currentSymb= null;
        clientwindow.window.location.href="http://"+clienthost+url;         clientwindow.window.location.href="http://"+clienthost+url;
    }     }
 }  }
   
 function gopost(url,postdata) {  function gopost(url,postdata) {
    windowcheck();     windowcheck();
    this.document['led'].src="ledsend.gif";     statuslocked=0;
      this.document['led'].src="http://"+clienthost+imgpath+"ledsend.gif";
    if (url!='') {     if (url!='') {
       this.document.server.action="http://"+clienthost+url;        this.document.server.action="http://"+clienthost+url;
       this.document.server.postdata.value=postdata;        this.document.server.postdata.value=postdata;
       this.document.server.command.value='';        this.document.server.command.value='';
       this.document.server.url.value='';        this.document.server.url.value='';
         this.document.server.symb.value='';
       this.document.server.submit();        this.document.server.submit();
    }     }
 }  }
   
 function gocmd(url,cmd) {  function gocmd(url,cmd) {
    windowcheck();     windowcheck();
    this.document['led'].src="ledsend.gif";     statuslocked=0;
      this.document['led'].src="http://"+clienthost+imgpath+"ledsend.gif";
    if (url!='') {     if (url!='') {
       this.document.server.action="http://"+clienthost+url;        this.document.server.action="http://"+clienthost+url;
       this.document.server.postdata.value='';        this.document.server.postdata.value='';
       this.document.server.command.value=cmd;        this.document.server.command.value=cmd;
       this.document.server.url.value=currentURL;        this.document.server.url.value=currentURL;
         this.document.server.symb.value=currentSymb;
       this.document.server.submit();        this.document.server.submit();
    }     }
 }  }
Line 344  function edit_bookmarks() { Line 357  function edit_bookmarks() {
 function catalog_info() {  function catalog_info() {
    go('');     go('');
    w_LONcatInfo_flag=1;     w_LONcatInfo_flag=1;
    loncatinfo=window.open(clientwindow.window.location.href+'.meta',"LONcatInfo");     loncatinfo=window.open(clientwindow.window.location.pathname+'.meta',"LONcatInfo");
 }  }
 // -->  // -->
 </script>  </script>
Line 371  function catalog_info() { Line 384  function catalog_info() {
 <tr><td bgcolor="#666666">  <tr><td bgcolor="#666666">
 <table hspace="0" border="0" cellspacing="1" cellpadding="0">   <table hspace="0" border="0" cellspacing="1" cellpadding="0"> 
 <tr>  <tr>
 <td><a href="javascript:defdis();" onMouseOver="defdis();"><img border="0"  name="i0" width="15" height="19" src="l.gif" /></a></td>  <td><a href="javascript:defdis();" onMouseOver="defdis();"><img border="0"  name="i0" width="15" height="19" src="/adm/lonLCDfont/l.gif" /></a></td>
 <td><a href="javascript:defdis();" onMouseOver="defdis();"><img border="0"  name="i1" width="15" height="19" src="o.gif" /></a></td>  <td><a href="javascript:defdis();" onMouseOver="defdis();"><img border="0"  name="i1" width="15" height="19" src="/adm/lonLCDfont/o.gif" /></a></td>
 <td><a href="javascript:defdis();" onMouseOver="defdis();"><img border="0"  name="i2" width="15" height="19" src="n.gif" /></a></td>  <td><a href="javascript:defdis();" onMouseOver="defdis();"><img border="0"  name="i2" width="15" height="19" src="/adm/lonLCDfont/n.gif" /></a></td>
 <td><a href="javascript:defdis();" onMouseOver="defdis();"><img border="0"  name="i3" width="15" height="19" src="hyphen.gif"></a></td>  <td><a href="javascript:defdis();" onMouseOver="defdis();"><img border="0"  name="i3" width="15" height="19" src="/adm/lonLCDfont/hyphen.gif"></a></td>
 <td><a href="javascript:defdis();" onMouseOver="defdis();"><img border="0"  name="i4" width="15" height="19" src="c.gif" /></a></td>  <td><a href="javascript:defdis();" onMouseOver="defdis();"><img border="0"  name="i4" width="15" height="19" src="/adm/lonLCDfont/c.gif" /></a></td>
 <td><a href="javascript:defdis();" onMouseOver="defdis();"><img border="0"  name="i5" width="15" height="19" src="a.gif" /></a></td>  <td><a href="javascript:defdis();" onMouseOver="defdis();"><img border="0"  name="i5" width="15" height="19" src="/adm/lonLCDfont/a.gif" /></a></td>
 <td><a href="javascript:defdis();" onMouseOver="defdis();"><img border="0"  name="i6" width="15" height="19" src="p.gif" /></a></td>  <td><a href="javascript:defdis();" onMouseOver="defdis();"><img border="0"  name="i6" width="15" height="19" src="/adm/lonLCDfont/p.gif" /></a></td>
 <td><a href="javascript:defdis();" onMouseOver="defdis();"><img border="0"  name="i7" width="15" height="19" src="a.gif" /></a></td>  <td><a href="javascript:defdis();" onMouseOver="defdis();"><img border="0"  name="i7" width="15" height="19" src="/adm/lonLCDfont/a.gif" /></a></td>
 </tr>  </tr>
 <tr>  <tr>
 <td><a href="javascript:defdis();" onMouseOver="defdis();"><img border="0" name="j0" width="15" height="19" src="space.gif" /></a></td>  <td><a href="javascript:defdis();" onMouseOver="defdis();"><img border="0" name="j0" width="15" height="19" src="/adm/lonLCDfont/space.gif" /></a></td>
 <td><a href="javascript:defdis();" onMouseOver="defdis();"><img border="0" name="j1" width="15" height="19" src="space.gif" /></a></td>  <td><a href="javascript:defdis();" onMouseOver="defdis();"><img border="0" name="j1" width="15" height="19" src="/adm/lonLCDfont/space.gif" /></a></td>
 <td><a href="javascript:defdis();" onMouseOver="defdis();"><img border="0" name="j2" width="15" height="19" src="space.gif" /></a></td>  <td><a href="javascript:defdis();" onMouseOver="defdis();"><img border="0" name="j2" width="15" height="19" src="/adm/lonLCDfont/space.gif" /></a></td>
 <td><a href="javascript:defdis();" onMouseOver="defdis();"><img border="0" name="j3" width="15" height="19" src="space.gif" /></a></td>  <td><a href="javascript:defdis();" onMouseOver="defdis();"><img border="0" name="j3" width="15" height="19" src="/adm/lonLCDfont/space.gif" /></a></td>
 <td><a href="javascript:defdis();" onMouseOver="defdis();"><img border="0" name="j4" width="15" height="19" src="space.gif" /></a></td>  <td><a href="javascript:defdis();" onMouseOver="defdis();"><img border="0" name="j4" width="15" height="19" src="/adm/lonLCDfont/space.gif" /></a></td>
 <td><a href="javascript:defdis();" onMouseOver="defdis();"><img border="0" name="j5" width="15" height="19" src="space.gif" /></a></td>  <td><a href="javascript:defdis();" onMouseOver="defdis();"><img border="0" name="j5" width="15" height="19" src="/adm/lonLCDfont/space.gif" /></a></td>
 <td><a href="javascript:defdis();" onMouseOver="defdis();"><img border="0" name="j6" width="15" height="19" src="space.gif" /></a></td>  <td><a href="javascript:defdis();" onMouseOver="defdis();"><img border="0" name="j6" width="15" height="19" src="/adm/lonLCDfont/space.gif" /></a></td>
 <td><a href="javascript:defdis();" onMouseOver="defdis();"><img border="0" name="j7" width="15" height="19" src="space.gif" /></a></td>  <td><a href="javascript:defdis();" onMouseOver="defdis();"><img border="0" name="j7" width="15" height="19" src="/adm/lonLCDfont/space.gif" /></a></td>
 </tr>  </tr>
 </table>  </table>
 </td></tr>  </td></tr>
Line 474  function catalog_info() { Line 487  function catalog_info() {
 <input type="hidden" name="postdata" value="none" />  <input type="hidden" name="postdata" value="none" />
 <input type="hidden" name="command" value="none" />  <input type="hidden" name="command" value="none" />
 <input type="hidden" name="url" value="none" />  <input type="hidden" name="url" value="none" />
   <input type="hidden" name="symb" value="none" />
 </form>  </form>
 <script>  <script>
 activate();  activate();

Removed from v.1.65  
changed lines
  Added in v.1.72


FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>