Like as the title of thread, I need to know way to insert images into web page HTML, the images will be encrypted base64. I found this example code
<img alt="Embedded Image" src="data:image/png;base64,iVBORw0KGgoAAAANSU" />
But I don't want this, I need more complex like:
<img alt="Embedded Image" src="data:image/png;base64,/path/to/file.txt" />
The file.txt is file containes base64 code. Thanks!
您需要一些可以读取文件的编程语言,例如PHP:
<img alt="Embedded Image" src="data:image/png;base64,<?= file_get_contents('/path/to/file.txt'); ?>" />
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.