I store the images in folder.
So how should I ask the user to upload images in the form?
I mean the user will upload the image using the upload button. Then after filling the form,
the user will submit it.
So when I am showing the contents of form again, how do I check which photo was related to which form .
Also how to position the image in a textarea?
Should I ask the user to put code <img src="example.com/images/name_of_image"/> in the textarea where he wants to display the image?
Is it safe to expose the image path to user?
Anyway I am answering form what I get your problem is. It is always better to write the complete programming part by the programmer and it is always better if the user enters only plain English. In my opinion if you are taking input form a user then use this technique.I am considering that you have a database and you are confortable using it.
1. Take input form a user and ask them to upload the image2. Make a PHP script to store the image in the webserver3. Create a table:+—-+————+————-+
|slno|username|imagename|
+—-+————+————-+
4. Now store the image name using $_FILES["file"]["name"]5. You can show your image form the user just by using a simple SELECT command.6. Make sure you have your unique id.Ref:Nice tutorial form w3schools.