[LON-CAPA-cvs] cvs: loncom /interface lonsimplepage.pm

amueller amueller@source.lon-capa.org
Mon, 07 Dec 2009 19:47:56 -0000


amueller		Mon Dec  7 19:47:56 2009 EDT

  Modified files:              
    /loncom/interface	lonsimplepage.pm 
  Log:
  -Dropped feature to delete a photo that was introduced in revision 1.62.
  Because LON-CAPA 2.81 doesn't support this feature, I go back to the roots. 
  
  
Index: loncom/interface/lonsimplepage.pm
diff -u loncom/interface/lonsimplepage.pm:1.86 loncom/interface/lonsimplepage.pm:1.87
--- loncom/interface/lonsimplepage.pm:1.86	Thu Nov 26 05:21:43 2009
+++ loncom/interface/lonsimplepage.pm	Mon Dec  7 19:47:56 2009
@@ -1,7 +1,7 @@
 # The LearningOnline Network
 # Simple Page Editor
 #
-# $Id: lonsimplepage.pm,v 1.86 2009/11/26 05:21:43 faziophi Exp $
+# $Id: lonsimplepage.pm,v 1.87 2009/12/07 19:47:56 amueller Exp $
 #
 # Copyright Michigan State University Board of Trustees
 #
@@ -232,13 +232,13 @@
         $syllabus{'uploaded.lastmodified'}=time;
         &Apache::lonnet::put($db_name,\%syllabus,$dom,$crs);
     }
-    if ($allowed && $env{'form.delupl'}) {
-        if ($syllabus{'uploaded.photourl'}) {
-            &Apache::lonnet::removeuploadedurl($syllabus{'uploaded.photourl'});
-            delete($syllabus{'uploaded.photourl'});
-            &Apache::lonnet::del('simplepage',['uploaded.photourl']);
-        }
-    }
+#    if ($allowed && $env{'form.delupl'}) {
+#        if ($syllabus{'uploaded.photourl'}) {
+#            &Apache::lonnet::removeuploadedurl($syllabus{'uploaded.photourl'});
+#            delete($syllabus{'uploaded.photourl'});
+#            &Apache::lonnet::del('simplepage',['uploaded.photourl']);
+#        }
+#    }
     if (($allowed) && ($env{'form.storesyl'})) {
         foreach my $syl_field (keys(%syllabusfields)) {
             my $field=$env{'form.'.$syl_field};
@@ -320,10 +320,10 @@
                   '<input type="submit" name="storeupl" value="'.&mt('Upload').'" />'.
                   '</form><form method="post" action="">'.
                   '<input type="hidden" name="forceedit" value="edit" />');
-            if ($syllabus{'uploaded.photourl'}) {
-                $r->print('<input type="submit" name="delupl"'
-                         .' value="'.&mt('Delete Photo').'" />');
-            }
+#            if ($syllabus{'uploaded.photourl'}) {
+#                $r->print('<input type="submit" name="delupl"'
+#                         .' value="'.&mt('Delete Photo').'" />');
+#            }
         }
         if ($allowed) {
             $r->print($image.'<div class="LC_footer_clear">&nbsp;</div>');