Diff for /loncom/interface/londocs.pm between versions 1.235 and 1.236

version 1.235, 2006/06/30 00:59:00 version 1.236, 2006/06/30 03:44:03
Line 1175  sub editor { Line 1175  sub editor {
 # Group import/search  # Group import/search
     if ($env{'form.importdetail'}) {      if ($env{'form.importdetail'}) {
  my @imports;   my @imports;
    &Apache::lonnet::logthis("imp detail ".$env{'form.importdetail'});
  foreach (split(/\&/,$env{'form.importdetail'})) {   foreach (split(/\&/,$env{'form.importdetail'})) {
     if (defined($_)) {      if (defined($_)) {
  my ($name,$url)=split(/\=/,$_);   my ($name,$url)=split(/\=/,$_);
Line 2726  sub editing_js { Line 2727  sub editing_js {
 function makenewfolder(targetform,folderseq) {  function makenewfolder(targetform,folderseq) {
     var foldername=prompt('Name of New Folder','New Folder');      var foldername=prompt('Name of New Folder','New Folder');
     if (foldername) {      if (foldername) {
        targetform.importdetail.value=foldername+"="+folderseq;         targetform.importdetail.value=escape(foldername)+"="+folderseq;
         targetform.submit();          targetform.submit();
     }      }
 }  }
Line 2734  function makenewfolder(targetform,folder Line 2735  function makenewfolder(targetform,folder
 function makenewpage(targetform,folderseq) {  function makenewpage(targetform,folderseq) {
     var pagename=prompt('Name of New Page','New Page');      var pagename=prompt('Name of New Page','New Page');
     if (pagename) {      if (pagename) {
         targetform.importdetail.value=pagename+"="+folderseq;          targetform.importdetail.value=escape(pagename)+"="+folderseq;
         targetform.submit();          targetform.submit();
     }      }
 }  }
Line 2748  function makeexamupload() { Line 2749  function makeexamupload() {
    var title=prompt('Listed Title for the Uploaded Score');     var title=prompt('Listed Title for the Uploaded Score');
    if (title) {      if (title) { 
     this.document.forms.newexamupload.importdetail.value=      this.document.forms.newexamupload.importdetail.value=
  title+'=/res/lib/templates/examupload.problem';   escape(title)+'=/res/lib/templates/examupload.problem';
     this.document.forms.newexamupload.submit();      this.document.forms.newexamupload.submit();
    }     }
 }  }
Line 2757  function makesmppage() { Line 2758  function makesmppage() {
    var title=prompt('Listed Title for the Page');     var title=prompt('Listed Title for the Page');
    if (title) {      if (title) { 
     this.document.forms.newsmppg.importdetail.value=      this.document.forms.newsmppg.importdetail.value=
  title+'=/adm/$udom/$uname/$now/smppg';   escape(title)+'=/adm/$udom/$uname/$now/smppg';
     this.document.forms.newsmppg.submit();      this.document.forms.newsmppg.submit();
    }     }
 }  }
Line 2766  function makesmpproblem() { Line 2767  function makesmpproblem() {
    var title=prompt('Listed Title for the Problem');     var title=prompt('Listed Title for the Problem');
    if (title) {      if (title) { 
     this.document.forms.newsmpproblem.importdetail.value=      this.document.forms.newsmpproblem.importdetail.value=
  title+'=/res/lib/templates/simpleproblem.problem';   escape(title)+'=/res/lib/templates/simpleproblem.problem';
     this.document.forms.newsmpproblem.submit();      this.document.forms.newsmpproblem.submit();
    }     }
 }  }
Line 2775  function makedropbox() { Line 2776  function makedropbox() {
    var title=prompt('Listed Title for the Drop Box');     var title=prompt('Listed Title for the Drop Box');
    if (title) {      if (title) { 
     this.document.forms.newdropbox.importdetail.value=      this.document.forms.newdropbox.importdetail.value=
         title+'=/res/lib/templates/DropBox.problem';          escape(title)+'=/res/lib/templates/DropBox.problem';
     this.document.forms.newdropbox.submit();      this.document.forms.newdropbox.submit();
    }     }
 }  }
Line 2784  function makebulboard() { Line 2785  function makebulboard() {
    var title=prompt('Listed Title for the Bulletin Board');     var title=prompt('Listed Title for the Bulletin Board');
    if (title) {     if (title) {
     this.document.forms.newbul.importdetail.value=      this.document.forms.newbul.importdetail.value=
  title+'=/adm/$udom/$uname/$now/bulletinboard';   escape(title)+'=/adm/$udom/$uname/$now/bulletinboard';
     this.document.forms.newbul.submit();      this.document.forms.newbul.submit();
    }     }
 }  }
   
 function makeabout() {  function makeabout() {
    var user=prompt("Enter user\@domain for User's 'About Me' Page");     var user=prompt("Enter user:domain for User's 'About Me' Page");
    if (user) {     if (user) {
        var comp=new Array();         var comp=new Array();
        comp=user.split('\@');         comp=user.split(':');
        if ((typeof(comp[0])!=undefined) && (typeof(comp[1])!=undefined)) {         if ((typeof(comp[0])!=undefined) && (typeof(comp[1])!=undefined)) {
    if ((comp[0]) && (comp[1])) {     if ((comp[0]) && (comp[1])) {
        this.document.forms.newaboutsomeone.importdetail.value=         this.document.forms.newaboutsomeone.importdetail.value=
    'About '+user+'=/adm/'+comp[1]+'/'+comp[0]+'/aboutme';     'About '+escape(user)+'=/adm/'+comp[1]+'/'+comp[0]+'/aboutme';
        this.document.forms.newaboutsomeone.submit();         this.document.forms.newaboutsomeone.submit();
    } else {     } else {
                alert("Not a valid user\@domain");                 alert("Not a valid user:domain");
            }             }
        } else {         } else {
            alert("Please enter both user and domain in the format user\@domain");              alert("Please enter both user and domain in the format user:domain"); 
        }         }
    }     }
 }  }

Removed from v.1.235  
changed lines
  Added in v.1.236


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