Jump to content

Recommended Posts

I'm trying to upload Multiple Images to my database and Every time I go to change/edit one of the images all of the images changes to the one I edited it to? The only want I can get different images in a entry is when I change them in the database.. any Ideas on how i can fix this for my client?

Link to comment
https://forums.phpfreaks.com/topic/148659-multiple-images/
Share on other sites

Post the code you're using. When updating the image you just edited make sure you query looks something like

UPDATE images SET image_name = 'new name', image_path = 'path/to/img' WHERE image_id = 123

 

The WHERE clause is very important in an UPDATE query. Without it MySQL will set all records within the table to the values you using in your query. The WHERE clause will only affect the record that matches the condition.

Link to comment
https://forums.phpfreaks.com/topic/148659-multiple-images/#findComment-780701
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.