I have this to upload a file from a form:
move_uploaded_file($HTTP_POST_FILES['simage']['tmp_name'],$store.$HTTP_POST_FILES['simage']['name'])
How can i change this to make it so the name of the file will become $id.jpg for example?
.
$up_img = move_uploaded_file($HTTP_POST_FILES["up_img"]["tmp_name"],$img_name);
this is what I use.
Will the entension be automatically added? such as saved as $image_name.jpg or .gif whatever it is?
. no. you have to set that (or have the user pick it)