Hi,
I have exported a simple word document as w2007 xml. This stores images as base64 it seems;
/9j/4AAQSkZJRgABAgEASABIAAD/wAARCAE3AwEDAREAAhEBAxEB/9sAhAABAQEBAQEBAQ +EBAQEB AQEBAQEBAQEBAQEBAQEBAQEBAQEBAQICAgECAgIBAQIDAgICAgMDAwECAwMDAgMCAgMCAQ +EBAQEB AQEBAQECAQEBAQICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAg +ICAgIC AgL/xAGiAAABBQEBAQEBAQAAAAAAAAAAAQIDBAUGBwgJCgsQAA
Seems simple. What I want to do is to convert a jpeg to base64, so I can import it into an xml .. and have word display it.
So I try;
use MIME::Base64 qw(encode_base64); open(FILE, "1.jpg") or die "$!"; binmode FILE; while (read(FILE, $buf, 60*57)) { print encode_base64($buf); }
And when I open the word document, the picture is rubbish. BUT i can see traces of the original picture, so im headed in the right direction at least.
Anyone got any advice on this? Thanks
In reply to Word 2007 XML format and perl by perlpreben
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |