Skip to content

<img src=''> puts entire HTML document into empty src #16

@naterm60

Description

@naterm60

Just like the title says. I found that my empty src attribute received a very long base64 string, so I decoded it, and it contains my index.html.

So I tried the recommended approach for empty src's, src='//:0' and got "No such file or directory: '//:0'". (See https://stackoverflow.com/questions/19126185/setting-an-image-src-to-empty/19126281).

Note that src='#' isn't recommended.

So I tried a 1 pixel image, which worked: src="data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7"

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions