i run this code to upload an image and it works perfectly on wampserver but when ever i test it on the hosted site it doesn't work, i activated the error reporting and there is no error but still no image uploaded, please if it is a permission issue on the server tell me how to fix it. thanks
if(isset($_POST['submit']) === true) {
$newname = "hello.jpg";
$location = 'img/products_img/';
move_uploaded_file($_FILES['image']['tmp_name'],$location.$newname);
}
and the form code is :
<form action="" method="post" enctype="multipart/form-data">
<input type="file" name="image" /> <br />
<input type="submit" name="submit" value="Upload Image" />
</form>