How to add GIF, BMP, and other image files to XML

Source: Internet
Author: User
How to add GIF, BMP, and other image files to XML Delphi/Windows SDK/API
Http://www.delphi2007.net/DelphiMultimedia/html/delphi_20060928214219282.html
As the question!
For example:
<Image>
Gif89a ....?....} Between M? Hot ?.. F then f... G then... _ PD then? Why? 5B !!?.....,.......... FP ?? 4 temple .? Why? 7. What are the vulnerabilities ?. C <too many. Why 8... why? @. #. Why P.../Why je? Wait... wait 8 minutes until then h $ .? ZB zookeeper vxz {B zookeeper ?.;
</Image>

Put in CDATA segment

In addition to XML, idhttp also includes the following parts:
Content-Type: image/GIF
Content-transfer-encoding: 8bit
Content-ID: test.gif
Content-location: test.gif

Gif89a ....?....} Between M? Hot ?.. F then f... G then... _ PD then? Why? 5B !!?.....,.......... FP ?? 4 temple .? Why? 7. What are the vulnerabilities ?. C <too many. Why 8... why? @. #. Why P.../Why je? Wait... wait 8 minutes until then h $ .? ZB zookeeper vxz {B zookeeper ?.;

Therefore, the above question is: it is impossible to use base64 encoding, and the server cannot modify it. data can only be transmitted in the preceding way.

At the same time, video and audio are also implemented through the above method. How can this problem be solved ??

You can use base64 encoding to save these images as text and put them in XML. When necessary, you can decode the base64 in XML, but why store images, videos, and other things in XML files? It seems that this is not a good idea. Isn't it better to store files directly?

Base64 encoding ~

"So the above question is: base64 encoding is not allowed, and the server cannot modify it. data can only be transmitted in the above way ."

Dear bosses, the server is an existing platform and cannot be modified. If base64 is used, the server needs to be decoded.

In addition, the server needs to use HTTP to transmit the data, instead of storing the data to a file and then transmitting images and video files.

actually, I understand the soap communication with attachments. Are you familiar with mime?

Contact Us

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.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.