[fpc-devel]RE: A bug in XMLWrite
Jeff Pohlmeyer
yetanothergeek at yahoo.com
Sun Jan 18 22:30:46 CET 2004
> I think I found a bug in XMLWrite unit.
> It doesn't convert '<' and '>' characters
> in attributes to '<' and '>'.
program xmlfix;
uses tidy;
procedure fix_xml_file(filename:shortstring);
var
Doc:tTidy;
f:text;
s:ansistring;
begin
Doc:=tTidy.Create(nil);
Doc.ErrorFile:=TIDY_NULL_FILE;
Doc.XmlTags:=True;
Doc.ParseFile(filename);
s:=Doc.XML;
assign(f, filename);
rewrite(f);
Write(f, s);
close(f);
Doc.Free;
end;
begin
fix_xml_file('info.xml');
end.
http://www.houston.quik.com/~jkp/tidypas/
__________________________________
Do you Yahoo!?
Yahoo! Hotjobs: Enter the "Signing Bonus" Sweepstakes
http://hotjobs.sweepstakes.yahoo.com/signingbonus
More information about the fpc-devel
mailing list