ค้นหา
!is_dir("$thumbsDir/{$this->type}") &&
!@mkdir("$thumbsDir/{$this->type}", $this->config['dirPerms'])
และแทนที่ด้วย
!is_dir("$thumbsDir/{$this->type}/".date("Y")) &&
!@mkdir("$thumbsDir/{$this->type}/".date("Y"), $this->config['dirPerms'])
จากนั้นให้เพิ่มโค๊ดด้านล่างนี้ ต่อจากโค๊ด $this->errorMsg("Cannot access or create thumbnails folder.");
if (
!is_dir($this->config['uploadDir']."/{$this->type}/".date("Y")) &&
!@mkdir($this->config['uploadDir']."/{$this->type}/".date("Y"), $this->config['dirPerms'])
)
$this->errorMsg("Cannot access or create upload folder.");
//Create SubFolder
if (
!is_dir("$thumbsDir/{$this->type}/".date("Y")."/".date("m")) &&
!@mkdir("$thumbsDir/{$this->type}/".date("Y")."/".date("m"), $this->config['dirPerms'])
)
$this->errorMsg("Cannot access or create thumbnails folder.");
if (
!is_dir($this->config['uploadDir']."/{$this->type}/".date("Y")."/".date("m")) &&
!@mkdir($this->config['uploadDir']."/{$this->type}/".date("Y")."/".date("m"), $this->config['dirPerms'])
)
$this->errorMsg("Cannot access or create upload folder.");
//
No comments:
Post a Comment