Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > XML > External entity as CDATA

Reply
Thread Tools

External entity as CDATA

 
 
Soren Kuula
Guest
Posts: n/a
 
      03-07-2004
Hi,

I want to include som XML and DTD files into a DocBook document .. and I
want the contents to remain unparsed. Sort of, instead of cpoying and
pasting the code into the DocBook document :

<programlisting>
<![CDATA[blah blah blah]]>
</programlisting>

I want

<!DOCTYPE ..... [
<!ENTITY blahfile SYSTEM "blahfile.dtd">
]>

<programlisting>
<![CDATA[&blahfile;]]>
</programlisting>

Of course the above does not expand the entity; just evaluates to its
name. But it should give in idea of what I am trying to do.

Any way ?

Soren

--
Fjern de 4 bogstaver i min mailadresse som er indsat for at hindre s...
Remove the 4 letter word meaning "junk mail" in my mail address.

 
Reply With Quote
 
 
 
 
Richard Tobin
Guest
Posts: n/a
 
      03-07-2004
In article <ZHJ2c.105909$(E-Mail Removed) >,
Soren Kuula <(E-Mail Removed)> wrote:

>I want to include som XML and DTD files into a DocBook document .. and I
>want the contents to remain unparsed. Sort of, instead of cpoying and
>pasting the code into the DocBook document :


I was going to say "that's impossible", but then I had an evil thought...

<!ENTITY % blahfile SYSTEM "blahfile.dtd">
<!ENTITY blahfile "<![CDATA[%blahfile;]]>">

You'll have to put that in an external subset, because you can't use
parameter entities that way in the internal subset. And you'd better
not have any CDATA sections in blahfile.

Don't tell anyone I suggested this.

-- Richard
--
Spam filter: to mail me from a .com/.net site, put my surname in the headers.

FreeBSD rules!
 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Entity Framework - Reassigning child entity's parent Norm ASP .Net 3 07-06-2009 07:28 PM
How to relate a SQL based entity with an Object based entity in Entity Framework markla ASP .Net 1 10-06-2008 09:42 AM
Entity Name or Entity Number? Samuel van Laere HTML 4 02-24-2007 10:11 PM
Can I un-CDATA my CDATA section and elaborate a transformation for the contained data? troppfigo@excite.it XML 3 03-06-2006 03:01 AM
Extracting CDATA Text without CDATA Tags??? John Davison Java 1 07-06-2004 11:00 PM



Advertisments