]> git.mjollnir.org Git - moodle.git/commitdiff
To avoid some unpleasant stuff with filters etc, I made slight changes
authormoodler <moodler>
Fri, 19 Mar 2004 08:18:13 +0000 (08:18 +0000)
committermoodler <moodler>
Fri, 19 Mar 2004 08:18:13 +0000 (08:18 +0000)
to separate the printing of the summary text from the edit button ...

Might need some testing because people have adjusted old texts to
work the old way ...   if anyone complains I'll put it back ...

course/format/topics/format.php
course/format/weeks/format.php

index 83f7baacab7283c943369e025d8813a4940dbf91..e27d08cb0b08c0de5d04a33d79fedc7d6783c934 100644 (file)
         echo "<td nowrap bgcolor=\"$THEME->cellheading\" class=\"topicsoutlineside\" valign=top width=20>&nbsp;</td>";
         echo "<td valign=top bgcolor=\"$THEME->cellcontent\" class=\"topicsoutlinecontent\" width=\"100%\">";
     
+        echo format_text($thissection->summary, FORMAT_HTML);
+
         if (isediting($course->id)) {
-            $thissection->summary .= " <a title=\"$streditsummary\" ".
-                                     "href=\"editsection.php?id=$thissection->id\"><img src=\"$CFG->pixpath/t/edit.gif\" ".
-                                     "height=11 width=11 border=0 alt=\"$streditsummary\"></a></p>";
+            echo "<a title=\"$streditsummary\" ".
+                 href=\"editsection.php?id=$thissection->id\"><img src=\"$CFG->pixpath/t/edit.gif\" ".
+                 " height=11 width=11 border=0 alt=\"$streditsummary\"></a><br />";
         }
     
-        echo format_text($thissection->summary);
+        echo '<br clear="all">';
     
         print_section($course, $thissection, $mods, $modnamesused);
     
         } else {
             echo "<td valign=top $colormain width=\"100%\">";
 
+            echo format_text($thissection->summary, FORMAT_HTML);
+
             if (isediting($course->id)) {
-                $thissection->summary .= " <a title=\"$streditsummary\" href=editsection.php?id=$thissection->id>".
-                     "<img src=\"$CFG->pixpath/t/edit.gif\" border=0 height=11 width=11></a>";
+                echo " <a title=\"$streditsummary\" href=editsection.php?id=$thissection->id>".
+                     "<img src=\"$CFG->pixpath/t/edit.gif\" border=0 height=11 width=11></a><br />";
             }
-    
-            echo format_text($thissection->summary);
+
+            echo '<br clear="all">';
     
             print_section($course, $thissection, $mods, $modnamesused);
     
index 64657906d0143c035d4e613e880710f440dbe9c5..fca6ac4c1826efb4d780f94e1d25c37b6514d3d7 100644 (file)
         echo "<td nowrap bgcolor=\"$THEME->cellheading\" class=\"weeklyoutlineside\" valign=top width=20>&nbsp;</td>";
         echo "<td valign=top bgcolor=\"$THEME->cellcontent\" class=\"weeklyoutlinecontent\" width=\"100%\">";
 
+        echo format_text($thissection->summary, FORMAT_HTML);
+
         if (isediting($course->id)) {
-            $thissection->summary .= " <a title=\"$streditsummary\" ".
-                                  "href=\"editsection.php?id=$thissection->id\"><img height=11 width=11 src=\"$CFG->pixpath/t/edit.gif\" ".
-                                  "border=0 alt=\"$streditsummary\"></a></p>";
+            echo " <a title=\"$streditsummary\" ".
+                 href=\"editsection.php?id=$thissection->id\"><img height=11 width=11 src=\"$CFG->pixpath/t/edit.gif\" ".
+                 " border=0 alt=\"$streditsummary\"></a><br />";
         }
-    
-        echo format_text($thissection->summary);
+
+        echo '<br clear="all">';
     
         print_section($course, $thissection, $mods, $modnamesused);
 
 
             echo "<p class=\"weeklydatetext\">$weekday - $endweekday</p>";
 
+            echo format_text($thissection->summary, FORMAT_HTML);
+
             if (isediting($course->id)) {
-                $thissection->summary .= " <a title=\"$streditsummary\" href=\"editsection.php?id=$thissection->id\">".
-                      "<img src=\"$CFG->pixpath/t/edit.gif\" height=11 width=11 border=0></a></p>";
+                echo " <a title=\"$streditsummary\" href=\"editsection.php?id=$thissection->id\">".
+                     "<img src=\"$CFG->pixpath/t/edit.gif\" height=11 width=11 border=0></a><br />";
             }
 
-            echo format_text($thissection->summary);
+            echo '<br clear="all">';
 
             print_section($course, $thissection, $mods, $modnamesused);