public function __construct($param = null) { parent::__construct($param); /* changed - now using wax root to allow for relative paths */ if (!is_dir(WAX_ROOT . $this->file_base)) { mkdir(WAX_ROOT . $this->file_base, 0777); } if (!is_dir(PUBLIC_DIR . $this->thumb_base)) { mkdir(PUBLIC_DIR . $this->thumb_base, 0777); } /* changed - now using wax root to allow for relative paths */ if (!is_writable(WAX_ROOT . $this->file_base)) { throw new WXPermissionsException("Files directory is not writable", WAX_ROOT . $this->file_base); } }