Hi,
I have made a script to handle an image upload and want the date to be in front of the image name when uploaded but does not seem to put the date in front and just uploads the image without the date in front. But all the code looks fine to me. I think i have been looking at it for too long tbh and will be something very easy.
PHP Code:
$date = time("DMY",strtotime("now"));
if($_POST['action']=='Add Entry'){
//handle image upload
if(is_uploaded_file($_FILES['image']['tmp_name']) && move_uploaded_file($_FILES['image']['tmp_name'], './images/'.$_FILES['image']['name']) && $_FILES['image']['size']<(1024*100)){
$imagefile = './images/'.$date.$_FILES['image']['name'];
}