Eklediğim Kod
$picture_1_tmp_name = $_FILES['picture_1']['tmp_name'];
$picture_1_new_name = $_FILES['picture_1']['name'];
$picture_1_clean_name = substr($picture_1_new_name, -4);
$picture_1_date = randomkeys(10);
$picture_1 = $picture_1_date . $picture_1_clean_name;
if (in_array($_FILES['picture_1']['type'], $types)) {
move_uploaded_file($picture_1_tmp_name, $fullpath . $picture_1);
} else {
$message = 'Error: Extension fail for Image!';
die($message);
}
}
if (!empty($_FILES['picture_2']['name'])) {
if ($_FILES['picture_2']['size'] == 0) {
$message = 'Error: Image (0 byte) « Go back!
';
die($message);
} elseif ($_FILES['picture_2']['size'] > 524288) {
$message = 'Error: Image (Max.: 512 k.byte)« Go back!
';
die($message);
}
$picture_2_tmp_name = $_FILES['picture_2']['tmp_name'];
$picture_2_new_name = $_FILES['picture_2']['name'];
$picture_2_clean_name = substr($picture_2_new_name, -4);
$picture_2_date = randomkeys(10);
$picture_2 = $picture_2_date . $picture_2_clean_name;
if (in_array($_FILES['picture_2']['type'], $types)) {
move_uploaded_file($picture_2_tmp_name, $fullpath . $picture_2);
} else {
$message = 'Error: Extension fail for Image!';
die($message);
}
}
Aldığım Hata;
Warning: move_uploaded_file(../event_images/P432ZXAJ01.png): failed to open stream: Permission denied in /home/celiltur/domains/celilturkyilmaz.com/public_html/template/portal/etkinlik/cp/act/event_manager.php on line 512
Warning: move_uploaded_file(): Unable to move '/tmp/php92HnbZ' to '../event_images/P432ZXAJ01.png' in /home/celiltur/domains/celilturkyilmaz.com/public_html/template/portal/etkinlik/cp/act/event_manager.php on line 512