imdata
Version 1.0.0 (1.35 KB) by
Thomas Spriestersbach
converts the image file content into data URI scheme (RFC-2397)
Use this script to convert image files into data URI scheme so that the image itself can be embedded into the image tag.
>> data = imdata('foo.png');
>> html = ['<img src="' data "'>'];
>> html
'<img src="data:image/png;base64,iVBORw0KGgoAAAANSUhEUg...">'
Cite As
Thomas Spriestersbach (2026). imdata (https://www.mathworks.com/matlabcentral/fileexchange/69332-imdata), MATLAB Central File Exchange. Retrieved .
MATLAB Release Compatibility
Created with
R2018b
Compatible with any release
Platform Compatibility
Windows macOS LinuxCategories
- MATLAB > External Language Interfaces > Web Services with MATLAB > Call Web Services from MATLAB Using HTTP >
Find more on Call Web Services from MATLAB Using HTTP in Help Center and MATLAB Answers
Tags
Discover Live Editor
Create scripts with code, output, and formatted text in a single executable document.
| Version | Published | Release Notes | |
|---|---|---|---|
| 1.0.0 |
