Jump to content

image upload


Brendan

Recommended Posts

Hey, im just curious as to what the best way to upload image files is from an upload form.

If i were to upload them directly to a mysql database it would use up the mysql database more than i would want. If i were to upload it to the server and have an entry in mysql which would point to each file, then i'm afraid the files and mysql entries could get mixed up or something to that extent, such as the file being created but having an error where a mysql entry isnt created.

Any suggestions?
Link to comment
Share on other sites

x[) this is why i don't use MySQL, just enumerate file names (0.jpg, 1.jpg, etc), put security on ur uploader so only certain file types are allowed, then enumerate displays with a function (a little while(file_exists("$num.jpg")) { } loop) and bam, you've avoided your problem
Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.