smart Posted April 16, 2012 Share Posted April 16, 2012 Hii have created custom cms using php and mysql there is option for image uploading in pages everything is working absolutly fine but when i edit the page and i did't upload any news image for update hit submit the image (input file upldated) goes blank in browser can anyone help.I just want if i Link to comment Share on other sites More sharing options...
justsomeguy Posted April 16, 2012 Share Posted April 16, 2012 You need to check if a file was uploaded and only process the file and upload the database if they uploaded a file. If a file was not uploaded then the error code for that in the $_FILES array is 4. So you only want to process the file if the error code is not 4. http://www.php.net/manual/en/features.file-upload.php Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now