]> git.mjollnir.org Git - moodle.git/commitdiff
Try to apply sensible file permissions to the new config.php
authormoodler <moodler>
Sat, 21 Aug 2004 13:27:44 +0000 (13:27 +0000)
committermoodler <moodler>
Sat, 21 Aug 2004 13:27:44 +0000 (13:27 +0000)
install.php

index 59a8dff7594576b5e416cab612d863a41978506b..fdc346888dd63774c65ce8d46a2059f568c48258 100644 (file)
@@ -303,10 +303,13 @@ if ($nextstage == 5) {
     $str .= '// RETURNS, OR ANYTHING ELSE AFTER THE TWO CHARACTERS ON THE NEXT LINE.'."\r\n";
     $str .= '?>';
 
+    umask(0137);
+
     if (( $configsuccess = ($fh = @fopen($configfile, 'w')) ) !== false) {
         fwrite($fh, $str);
         fclose($fh);
     }
+        
 
     $INSTALL['config'] = $str;
 }
@@ -577,6 +580,7 @@ function form_table($nextstage = 0, $formaction = "install.php") {
             <?php echo ($nextstage < 5) ? "<input type=\"submit\" name=\"next\" value=\"".get_string('next')."  &raquo;\" style=\"float: right\"/>\n" : "&nbsp;\n" ?>
             <?php echo ($nextstage > 0) ? "<input type=\"submit\" name=\"prev\" value=\"&laquo;  ".get_string('previous')."\" style=\"float: left\"/>\n" : "&nbsp;\n" ?>
 
+
         </td>
 
     </tr>