Jump to content

Upload images to database


Anders Moen

Recommended Posts

Anyone got a code so I can upload images to my database?The table will get an ID which will have auto_increment, so I want the picture to be renamed to the same as the ID it'll come up under. I also want it to be resized to for example width: 300px and height: 200px.For example:First time I insert, the image should be renamed to 1.jpg or 1.gif or whatever else, after what filetype it is.The second time I insert, that second image should be renamed to 2.jpg/gif/bmp or whateverAnd then it just continues. So anyone got the code for this?

Link to comment
Share on other sites

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...