Recently writing interface ———— about image upload
The foreground uses the Vuejs, uses the base64 to upload the picture, filedata: "Data:image/jpeg;base64,9j/4aaqsk ...", puts this data directly in the address bar, also can display the picture, But
Data/base64 webmasters often use more data. I often see that they generate data/base64 data for images and then input the data. This shows a very long string, now let's take a look at the php input method. Let's take a look at data/B.
Data/base64
Base64 URL Image CSSThe Data URI scheme is defined in the RFC2397SVG path line width: stroke-widthOnline Base64 encryption/decryption Link:So what is this? This is the data URI scheme.The data URI scheme is defined in RFC2397 to embed some small
Database64 webmasters often use more data. I often see that they generate database64 data for images and then input it. This shows a long string, now let's take a look at the php input method. Data/base64 webmasters often use more data. I often see
Let's see what Data/base64 is.
What is Data:image/*;base64?
Answer: This is Data URI scheme.Don't you understand?Ps:data URI scheme is defined in RFC2397 to embed some small data directly into a Web page so that you do not have to load it from an
I. BASE64 code ORIGINWhy do you have Base64 code? Because some network transport channels do not support all bytes, such as traditional mail only supports the transmission of visible characters, such as ASCII code control characters can not be
The data URI scheme is defined in RFC2397 to embed some small data directly into the Web page without having to load it from an external file.
Advantages: Reduce the number of HTTP connections.
Disadvantage: Files of this format will not be cached
Data URI Scheme. Data URI scheme is defined in RFC2397 to embed some small data directly into a Web page so that no longer has to be loaded from an external file. For example, the above string of characters, in fact, is a small picture, these
When realizing the function of Html2canvas, it is found that "picture cross-domain" is not supported, which is a headache;Accidentally found that if the "online picture resources" converted to Base64, with Base64 rendering, so that the perfect
The example of this article is about how to display the PHP image in base64. Share to everyone for your reference, specific as follows:
Here the implementation of the picture as a string saved to the Web page, so that no longer need to load the
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.