]> git.mjollnir.org Git - moodle.git/commitdiff
More XHTML fixes
authormoodler <moodler>
Fri, 15 Oct 2004 12:23:43 +0000 (12:23 +0000)
committermoodler <moodler>
Fri, 15 Oct 2004 12:23:43 +0000 (12:23 +0000)
mod/resource/index.php
mod/resource/type/common.html
mod/resource/type/directory/resource.class.php
mod/resource/type/html/html.html
mod/resource/type/html/resource.class.php
mod/resource/type/text/resource.class.php
mod/resource/type/text/text.html

index 0dc4f684031a951ccc635540490e8004325d8907..dfe27f4b4627bd11e7191e7f4346cc0daf71d390 100644 (file)
 
     if ($course->format == "weeks") {
         $table->head  = array ($strweek, $strname, $strsummary);
-        $table->align = array ("CENTER", "LEFT", "LEFT");
+        $table->align = array ("center", "left", "left");
     } else if ($course->format == "topics") {
         $table->head  = array ($strtopic, $strname, $strsummary);
-        $table->align = array ("CENTER", "LEFT", "LEFT");
+        $table->align = array ("center", "left", "left");
     } else {
         $table->head  = array ($strlastmodified, $strname, $strsummary);
-        $table->align = array ("LEFT", "LEFT", "LEFT");
+        $table->align = array ("left", "left", "left");
     }
 
     $currentsection = "";
index b9d849812e940bf0877ce4a81c8419c7776c68a8..980e016c8be4be7ee9641259cad97751eb1e0a0c 100644 (file)
@@ -13,7 +13,7 @@
 <tr valign="top">
     <td align="right"><p><b><?php print_string("name") ?>:</b></p></td>
     <td>
-        <input type="text" name="name" size="65" value="<?php p($form->name) ?>" />
+        <input type="text" name="name" size="65" value="<?php p($form->name) ?>" alt="<?php print_string("name") ?>" />
     </td>
 </tr>
 <tr valign="top">
index f17c47b1c0b5c98d527270b788e492f38c604625..09273b22e65c89e788d7332403224a568211da4e 100644 (file)
@@ -119,7 +119,7 @@ function display() {
 
         echo '<tr>';
         echo '<td>';
-        echo "<img src=\"$CFG->pixpath/f/$icon\" width=\"16\" height=\"16\" />";
+        echo "<img src=\"$CFG->pixpath/f/$icon\" width=\"16\" height=\"16\" alt=\"\"/>";
         echo '</td>';
         echo '<td nowrap="nowrap"><p>';
         if ($icon == 'folder.gif') {
index 77c1b8cb0ee4d79d35653ee22a1566165ec77177..445c2bee597648aaedd6ec5e7b39e6432c82e679 100644 (file)
@@ -1,4 +1,9 @@
-<script language="javascript">
+
+<tr valign="top">
+    <td align="right" nowrap="nowrap">
+
+
+<script language="javascript" type="text/javascript">
     function showhide (id, set) {
         divobj = document.getElementById(id);
         butobj = document.getElementById(id+'button');
@@ -26,8 +31,6 @@
 </script>
 
 
-<tr valign="top">
-    <td align="right" nowrap="nowrap">
         <p><b><?php print_string("fulltext", "resource") ?>:</b></p><br />
         <font size="1">
             <?php  helpbutton("writing", get_string("helpwriting"), "moodle", true, true) ?><br />
@@ -77,7 +80,7 @@
         <input name="windowpopup" type="radio" value="1" <?php echo ($windowtype == "popup") ? "checked=\"checked\"" : "" ?>
         onclick=" return lockoptions('form', 'windowpopup[1]', popupitems);" />
         <b title="<?php p($strnewwindowopen) ?>"><?php p($strnewwindow) ?></b>
-        <ul>
+        <blockquote>
         <?php
             foreach ($window as $name => $value) {
                 if ($name == "height" or $name == "width") {
                 echo "</script>";
             }
         ?>
-        </ul>
+        </blockquote>
     </td>
 </tr>
 
 
     </div>
 
-</td></tr>
-
 
-<script language="javascript">
+<script language="javascript" type="text/javascript">
     showhide('windowsettings', true);
 </script>
 
+
+</td></tr>
+
index 9034ecf7c3419bd31b7fa4ccfd6dd91c3be211e9..38acb2d14e9346f8d78243e680e00f7cdfa14482 100644 (file)
@@ -110,9 +110,9 @@ function display() {
                          "", "", true, update_module_button($this->cm->id, $course->id, $strresource), 
                          navmenu($course, $this->cm));
 
-            echo "\n<script language=\"Javascript\">";
+            echo "\n<script language=\"javascript\" type=\"text/javascript\">";
             echo "\n<!--\n";
-            echo "openpopup('/mod/resource/view.php?inpopup=true&amp;id={$this->cm->id}','resource{$resource->id}','{$resource->popup}');\n";
+            echo "openpopup('/mod/resource/view.php?inpopup=true&id={$this->cm->id}','resource{$resource->id}','{$resource->popup}');\n";
             echo "\n-->\n";
             echo '</script>';
     
@@ -132,6 +132,7 @@ function display() {
             print_footer($course);
         }
     } else {    /// not a popup at all
+        die;
 
         add_to_log($course->id, "resource", "view", "view.php?id={$this->cm->id}", $resource->id, $this->cm->id);
         print_header($pagetitle, $course->fullname, "$navigation {$resource->name}",
@@ -140,7 +141,7 @@ function display() {
     
         print_simple_box(format_text($resource->alltext, FORMAT_HTML, $formatoptions, $course->id), "center", "", "$THEME->cellcontent", "20");
     
-        echo "<center><p><font size=\"1\">$strlastmodified: ".userdate($resource->timemodified)."</p></center>";
+        echo "<center><p><font size=\"1\">$strlastmodified: ".userdate($resource->timemodified)."</font></p></center>";
     
         print_footer($course);
     }
@@ -190,7 +191,7 @@ function setup($form) {
                 if ($optionname == "height" or $optionname == "width") {
                     $window->$optionname = $optionvalue;
                 } else if ($optionvalue) {
-                    $window->$optionname = "checked";
+                    $window->$optionname = "checked=\"checked\"";
                 }
             }
         }
index 9e6eec54fc222ab2e5b91e8aea8c713f000e72df..8c0c2c09aee42312237267d44fcca6593fe98d56 100644 (file)
@@ -102,15 +102,16 @@ function display() {
             print_header();
             print_simple_box(format_text($resource->alltext, $resource->options, $formatoptions, $course->id), 
                              "center", "", "$THEME->cellcontent", "20");
+            print_footer($course);
         } else {                           /// Make a page and a pop-up window
 
             print_header($pagetitle, $course->fullname, "$navigation {$resource->name}", 
                          "", "", true, update_module_button($this->cm->id, $course->id, $strresource), 
                          navmenu($course, $this->cm));
 
-            echo "\n<script language=\"Javascript\">";
+            echo "\n<script language=\"javascript\" type=\"text/javascript\">";
             echo "\n<!--\n";
-            echo "openpopup('/mod/resource/view.php?inpopup=true&amp;id={$this->cm->id}','resource{$resource->id}','{$resource->popup}');\n";
+            echo "openpopup('/mod/resource/view.php?inpopup=true&id={$this->cm->id}','resource{$resource->id}','{$resource->popup}');\n";
             echo "\n-->\n";
             echo '</script>';
     
@@ -139,7 +140,7 @@ function display() {
         print_simple_box(format_text($resource->alltext, $resource->options, $formatoptions, $course->id), 
                          "center", "", "$THEME->cellcontent", "20");
     
-        echo "<center><p><font size=\"1\">$strlastmodified: ".userdate($resource->timemodified)."</p></center>";
+        echo "<center><p><font size=\"1\">$strlastmodified: ".userdate($resource->timemodified)."</font></p></center>";
     
         print_footer($course);
     }
@@ -191,7 +192,7 @@ function setup($form) {
                 if ($optionname == "height" or $optionname == "width") {
                     $window->$optionname = $optionvalue;
                 } else if ($optionvalue) {
-                    $window->$optionname = "checked";
+                    $window->$optionname = "checked=\"checked\"";
                 }
             }
         }
index 235f2688d2568d8bfea593b8374428153d309730..ce7eb587c827e5577243500c0512333f3425ef52 100644 (file)
@@ -1,4 +1,9 @@
-<script language="javascript">
+
+<tr valign="top">
+    <td align="right" nowrap="nowrap">
+
+
+<script language="javascript" type="text/javascript">
     function showhide (id, set) {
         divobj = document.getElementById(id);
         butobj = document.getElementById(id+'button');
@@ -27,8 +32,6 @@
 
 
 
-<tr valign="top">
-    <td align="right" nowrap="nowrap">
         <p><b><?php print_string("fulltext", "resource") ?>:</b></p><br />
         <font size="1">
             <?php  helpbutton("writing", get_string("helpwriting"), "moodle", true, true) ?><br />
@@ -91,7 +94,7 @@
         onclick=" return lockoptions('form', 'windowpopup[1]', popupitems);" />
         <b title="<?php p($strnewwindowopen) ?>"><?php p($strnewwindow) ?></b>
         <?php p($strnewwindowopen) ?>
-        <ul>
+        <blockquote>
         <?php
             foreach ($window as $name => $value) {
                 if ($name == "height" or $name == "width") {
                 echo "</script>";
             }
         ?>
-        </ul>
+        </blockquote>
     </td>
 </tr>
 
 
     </div>
 
-</td></tr>
-
 
-<script language="javascript">
+<script language="javascript" type="text/javascript">
     showhide('windowsettings', true);
 </script>
 
+
+</td></tr>
+
+
+