]> git.mjollnir.org Git - moodle.git/commitdiff
Bug #5684 - frameset page in UTF8 doesn't appear on IE; merged from MOODLE_16_STABLE
authorskodak <skodak>
Thu, 1 Jun 2006 14:50:41 +0000 (14:50 +0000)
committerskodak <skodak>
Thu, 1 Jun 2006 14:50:41 +0000 (14:50 +0000)
mod/workshop/assess.php
mod/workshop/viewassessment.php

index 814547973e9e8ebfa9ecbd1c386f71adeebfe976..32a90d6b068093333b5460eea4eec212fdf0219b 100644 (file)
     /// Now check whether we need to display a frameset
 
     if (empty($frameset)) {
-        echo "<head><title>{$course->shortname}: ".format_string($workshop->name,true)."</title></head>\n";
+        $encoding = current_charset();
+        if ( get_string('thisdirection') == 'rtl' ) {
+            $direction = ' dir="rtl"';
+        } else {
+            $direction = ' dir="ltr"';
+        }
+        echo "<!DOCTYPE html PUBLIC \"-//W3C//DTD XHTML 1.0 Frameset//EN\" \"http://www.w3.org/TR/xhtml1/DTD/xhtml1-frameset.dtd\">\n";
+        echo "<html $direction>\n";
+        echo "<head><meta http-equiv=\"content-type\" content=\"text/html; charset=$encoding\" />\n";
+        echo "<title>{$course->shortname}: ".format_string($workshop->name,true)."</title></head>\n";
         echo "<frameset rows=\"50%,*\" border=\"10\">";
-        echo "<frame src=\"assess.php?id=$id&amp;sid=$sid&amp;frameset=top&amp;redirect=$redirect\" border=\"10\">";
-        echo "<frame src=\"assess.php?id=$id&amp;sid=$sid&amp;frameset=bottom&amp;redirect=$redirect\">";
+        echo "  <frame src=\"assess.php?id=$id&amp;sid=$sid&amp;frameset=top&amp;redirect=$redirect\" border=\"10\" />";
+        echo "  <frame src=\"assess.php?id=$id&amp;sid=$sid&amp;frameset=bottom&amp;redirect=$redirect\" />";
         echo "</frameset>";
+        echo "</html>";
         exit;
     }
 
index ac058d76f38eff3d45fd6e7f21659325af121f79..c3db61625d4d5a3995098680676ec42409ab0d04 100644 (file)
     /// Now check whether we need to display a frameset
 
     if (empty($frameset)) {
-        echo "<head><title>{$course->shortname}: ".format_string($workshop->name,true)."</title></head>\n";
+        $encoding = current_charset();
+        if ( get_string('thisdirection') == 'rtl' ) {
+            $direction = ' dir="rtl"';
+        } else {
+            $direction = ' dir="ltr"';
+        }
+        echo "<!DOCTYPE html PUBLIC \"-//W3C//DTD XHTML 1.0 Frameset//EN\" \"http://www.w3.org/TR/xhtml1/DTD/xhtml1-frameset.dtd\">\n";
+        echo "<html $direction>\n";
+        echo "<head><meta http-equiv=\"content-type\" content=\"text/html; charset=$encoding\" />\n";
+        echo "<title>{$course->shortname}: ".format_string($workshop->name,true)."</title></head>\n";
         echo "<frameset rows=\"90%,*\" border=\"10\">";
-        echo "<frame src=\"viewassessment.php?id=$id&amp;aid=$aid&amp;allowcomments=$allowcomments&amp;frameset=top&amp;redirect=$redirect\" border=\"10\">";
-        echo "<frame src=\"viewassessment.php?id=$id&amp;aid=$aid&amp;allowcomments=$allowcomments&amp;frameset=bottom&amp;redirect=$redirect\">";
+        echo "  <frame src=\"viewassessment.php?id=$id&amp;aid=$aid&amp;allowcomments=$allowcomments&amp;frameset=top&amp;redirect=$redirect\" border=\"10\" />";
+        echo "  <frame src=\"viewassessment.php?id=$id&amp;aid=$aid&amp;allowcomments=$allowcomments&amp;frameset=bottom&amp;redirect=$redirect\" />";
         echo "</frameset>";
+        echo "</html>";
         exit;
     }