HTML character entities in XML files
Lynne A. Price
lprice at txstruct.com
Mon Jan 9 15:49:52 PST 2006
At 11:32 AM 1/9/2006, Mark Barratt wrote:
>In this case I need to suck in xhtml character entities but save out
>UTF-8-encoded Unicode for the next application in the workflow
Mark,
Create two versions of the DTD, one with the entity declarations and one
without. Use the one with the entity declarations to import your document
and the one without the declarations for export. I'd create the following
files:
main.dtd (element type and attribute definition list declarations)
entity.mod (module with entity declarations)
main.entity.dtd:
<!ENTITY % main SYSTEM "main.dtd">
%main;
<!ENTITY % entity SYSTEM "entity.mod">
&entity;
Then I'd import files that start:
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE xxx SYSTEM "main.entity.dtd">
However, I'd specify main.dtd as the DTD in the XML application.
--Lynne
Lynne A. Price
Text Structure Consulting, Inc.
Specializing in structured FrameMaker consulting, application development,
and training
lprice at txstruct.com http://www.txstruct.com
voice/fax: (510) 583-1505 cell phone: (510) 421-2284
More information about the framers
mailing list