Skip to content
Advertisement

How to let users upload or change the uploaded images in one page, and display it in another page? [closed]

How to let user upload image in one page, and then display it in another page? User can change the image and it’ll be changed also in the other page. Also, I’m talking about using php / js / jquery / mysqli anything that’s most efficient. (I’m just a beginner in this field so it’ll be appreciated if you use some simple language :))

Edit: Yes I said that I’m a beginner, but that doesn’t mean I don’t know a thing about coding. Also, I saw a few solutions from youtube & other stackoverflows questions, but all of them is about either uploading and displaying in the same page or not being able to change the image.

Advertisement

Answer

  1. Format the image into Base64 string
  2. store it in local-storage
  3. In another page get it from local-storage and assign to the id or class.

Suggesting the link that already have answered for How to save an image to localStorage and display it on the next page?

Advertisement