diff --git a/includes/utilities.php b/includes/utilities.php index 29c32689..8e1a2197 100644 --- a/includes/utilities.php +++ b/includes/utilities.php @@ -457,6 +457,7 @@ class Timer abstract class Util { const FILE_ACCESS = 0755; + const DIR_ACCESS = 0777; const GEM_SCORE_BASE_WOTLK = 16; // rare quality wotlk gem score const GEM_SCORE_BASE_BC = 8; // rare quality bc gem score @@ -1392,13 +1393,13 @@ abstract class Util if (is_dir($dir)) { - if (!is_writable($dir) && !@chmod($dir, Util::FILE_ACCESS)) + if (!is_writable($dir) && !@chmod($dir, Util::DIR_ACCESS)) trigger_error('cannot write into directory', E_USER_ERROR); return is_writable($dir); } - if (@mkdir($dir, Util::FILE_ACCESS, true)) + if (@mkdir($dir, Util::DIR_ACCESS, true)) return true; trigger_error('could not create directory', E_USER_ERROR); diff --git a/setup/tools/fileGen.class.php b/setup/tools/fileGen.class.php index 33927f9d..1704019e 100644 --- a/setup/tools/fileGen.class.php +++ b/setup/tools/fileGen.class.php @@ -49,12 +49,13 @@ class FileGen public static $defaultExecTime = 30; private static $reqDirs = array( - 'static/uploads/screenshots/normal', - 'static/uploads/screenshots/pending', - 'static/uploads/screenshots/resized', - 'static/uploads/screenshots/temp', - 'static/uploads/screenshots/thumb', + 'static/uploads/screenshots/normal/', + 'static/uploads/screenshots/pending/', + 'static/uploads/screenshots/resized/', + 'static/uploads/screenshots/temp/', + 'static/uploads/screenshots/thumb/', 'static/uploads/temp/', + 'static/uploads/guide/images/', 'static/download/searchplugins/', 'static/wowsounds/' );