Select an image to insert into a form?

I’m putting together a site that will allow users to submit a link, click submit and be taken to a page where a few images, meta description, etc., has been scraped. This is basically what facebook or pinterest does when users paste a link. My question is how to allow the user to select one of those images and insert it into the form so it can be submitted to the database?

Maybe this isn’t even something jQuery can do and I’m in the wrong forum? If that’s the case, I apologize.

Thanks in advance.