zey_ser
Новичок
Добрый день!
При
получаю chmod(): Operation not permitted
Текущий пользователь(whoami) - apache
$uplod_file - Пользователь - zoo, Группа - apache
Дело происходит на шаред хостинге. Не могу понять как решить проблему! Прошу вашей помощи!
Часть рабочего кода
При
Код:
chmod($uplod_file , 0664);
Текущий пользователь(whoami) - apache
$uplod_file - Пользователь - zoo, Группа - apache
Дело происходит на шаред хостинге. Не могу понять как решить проблему! Прошу вашей помощи!
Часть рабочего кода
Код:
// Получаем данные
$data = file_get_contents("php://input");
if ($data !== false) {
file_put_contents($uplod_file, $data);
if ($fp = fopen($uplod_file, "wb")) {
$result = fwrite($fp, $data);
if ($result === strlen($data)) {
// chmod($uplod_file , 0664);
$this->echo_message(1, "The file " . $this->request->get['filename'] . " has been successfully uploaded");
$xmlfiles = $this->extractZip($uplod_file);
//unlink($uplod_file);
}
else {
$this->echo_message(0, "Empty file " . $this->request->get['filename']);
}
}
else {
$this->echo_message(0, "Can not open file " . $this->request->get['filename']);
}
}