DEV Community

Discussion on: 10 useful HTML file upload tips for web developers

Collapse
 
danielfinke profile image
Daniel Finke

Hi Tapas, I was just examining the src attribute of the image in the iframe after the image was uploaded.

I figured out why I was confused though. In your post, the CodePen iframe has the src value https://codepen.io/atapas/embed/BazzaoN?height=600&default-tab=result&embed-version=2. But I didn't notice last time that there was a sub-iframe that CodePen put in with src value https://cdpn.io/atapas/fullembedgrid/BazzaoN?animations=run&type=embed. So it seems like the blob URL is just based on the URL of the page or frame that the JS is running in.

Seems kind of weird that the browser adds the domain in when the blob is local to you machine only anyway

Thread Thread
 
atapas profile image
Tapas Adhikary

Sure, thanks Daniel.