As said, that image is just an example, but let's use it, how can I find the XML for that image? I've tried using HEX Viewer, but that didn't help at all, I've tried open a Wordpad, save it as .xml, and put a image in, but that doesn't work either.
well, a typical xml document will look similar to a simple html document. you will have tags, and within those tags will be options. The trick to xml, however, is tags and options can be anything you desire, not set in stone like html.
An example xml compilation for an image could be something like this:
<src>the url to the image</src>
<height> image height in pixels</height>
<width> image width in pixels</width>
<title> whatever title you want for the image</title>
I have Base64, but don't know how do use it with images.
You would read the binary data and encode the data in base64. The data would then be placed into an XML document, such as:
<description>A black dot. Size: 1px x 1px.</description>
Of course, yours would most likely be considerably longer since that is for a 1x1 black GIF image. If all you're trying to do is store the image, then that's it; you're finished. If you actually want to display it in a browser, then you would use XSLT, mapping image/src in your XML document to img/@src in your transformation. That would essentially make the data useless unless you planned to use it for another purpose.