[LON-CAPA-cvs] cvs: loncom /publisher publisher.html

albertel lon-capa-cvs@mail.lon-capa.org
Tue, 04 Feb 2003 21:05:12 -0000


albertel		Tue Feb  4 16:05:12 2003 EDT

  Modified files:              
    /loncom/publisher	publisher.html 
  Log:
  
  - adds back in delete
  - fixes form submission, del,copy,rename,new subdir work
  
  
  
Index: loncom/publisher/publisher.html
diff -u loncom/publisher/publisher.html:1.24 loncom/publisher/publisher.html:1.25
--- loncom/publisher/publisher.html:1.24	Tue Feb  4 15:33:19 2003
+++ loncom/publisher/publisher.html	Tue Feb  4 16:05:12 2003
@@ -57,6 +57,11 @@
    document.fileaction.submit();
 }
 
+function getdelfilename() {
+  document.del.filename.value=parent.LONCAPAToBePublished.location.href;
+  document.del.submit();
+}
+
 function getpostdata() {
   document.printout.postdata.value=parent.LONCAPAToBePublished.location.href;
   document.printout.submit();
@@ -87,6 +92,13 @@
 		      <input type="button" value="Upload file"  onClick="getufilename();" />
 		    </td>
 		  </form>
+		  <form name="printout" target="_parent" action="/adm/printout" target="LONCAPAToBePublished" method="post" onSubmit="getpostdata();">
+		    <td rowspan="2" bgcolor="#ccddaa" align="center">
+		      <input type="hidden" name="postdata" value="" />
+		      <input type="button" value="Print" onClick="getpostdata();" />
+		    </td>
+		  </form>
+
 		</tr>
 		<tr valign="middle">
 		  <form name="rpublisher" action="/adm/retrieve" target="_parent" method="post">
@@ -95,10 +107,11 @@
 		      <input type="button" value="Retrieve Old Version" onClick="getrfilename();" />
 		    </td>
 		  </form>
-		  <form name="printout" target="_parent" action="/adm/printout" target="LONCAPAToBePublished" method="post" onSubmit="getpostdata();">
-		    <td bgcolor="#ccddaa" align="center">
-		      <input type="hidden" name="postdata" value="" />
-		      <input type="button" value="Print" onClick="getpostdata();" />
+		  <form name="del" action="/adm/cfile" target="_parent" method="post">
+		    <td bgcolor="#ccddaa">
+		      <input type="hidden" name="filename" value="" />
+		      <input type="hidden" name="action" value="delete" />
+	              <input type="button" value="Delete" onClick="getdelfilename();" />
 		    </td>
 		  </form>
 		  <form name="fileaction" action="/adm/cfile" target="_parent" method="post">
@@ -110,10 +123,10 @@
 			    <option value="newfile">New file:</option>
 			    <option value="newhtmlfile">New HTML file:</option>
 			    <option value="newproblemfile">New problem:</option>
-			    <option value="newsubdir">New subdirectory:</option>
+			    <option value="newdir">New subdirectory:</option>
 			    <option value="rename">Rename current file to:</option>
 			    <option value="copy">Copy current file to:</option>
-			  </select>&nbsp;<input type="text" name="filename" value="Type Name Here" onFocus="if (this.value == 'Type Name Here') this.value=''" />&nbsp;<input type="button" value="Go" onClick="getactionfilename();" />
+			  </select>&nbsp;<input type="text" name="newfilename" value="Type Name Here" onFocus="if (this.value == 'Type Name Here') this.value=''" />&nbsp;<input type="button" value="Go" onClick="getactionfilename();" />
 		      </nobr>
 		    </td>
 		  </form>