I would like to offer my client the option of a form to upload stock to the database with 4 images.

I have found plenty of scripts to do this, but the other part I need is for my client to be able to go back to that stock item and if needed change all of the images, or maybe just one of the four if needed.

Can somebody point me to a good understandable tutorial, or if they maybe have a script to handy to paste back.

The form I currently have is that the form is empty once in the page ready to add stock to the database, and then on the same page they can select an item to edit any part of the stock, and I need to have the option of being able to edit the images, and if one isnt changed it keeps the image that is currently in the database.

Thanks

LeonardChallis
—
2012-03-16T23:53:10Z —
#2

Have you implemented the initial upload part yet? There are plenty of ways to do this so it is a lot easier to suggest something if we know how you're doing it partly. That said, if you haven't and want to get a good idea, I'd definitely suggest finding some open source software that does it how you like and checking out the code, or even just letting readers of this post know so they can advise on how that's achieved.

Most odd. There's NO reason for those double quotes to be there apart from making the code take longer to execute.

multichild
—
2012-03-17T16:56:05Z —
#6

Hi Shaydez,

That looks good and very complicated.

If you could spare me a bit more info I would be very grateful so I can get my bearings.

Can you put the html to it, so that I can see how you put it all together.

Cheers

multichild
—
2012-03-19T08:18:59Z —
#7

I'm looking at Shaydez code above and it looks great as far as I can tell as a novice, but what I cant work out is how would the form look to get this working, and how do I connect that code to my database to allow me to upload the image path to the table, so I can retrieve it on the web page.

This is a step up, as you can tell from my work, so if anyone can help me create the full workings from the form, to the image upload script to then pushing the images into the database that would be great.

I am going to make a start this morning, and see if I can figue it out.

Cheers

multichild
—
2012-03-19T09:50:12Z —
#8

Hi, OK I can see how that code by Shaydez works, and have set it so the client has up to 4 images they can upload.

It might be a bit too much but I have pasted the full page below, and beneath that I have posted the code by shaydez and my bit and where I will need some help.