You are viewing a plain text version of this content. The canonical link for it is here.
Posted to fop-users@xmlgraphics.apache.org by RAYMOND Romain <ro...@c-s.fr> on 2002/04/04 17:53:23 UTC

.fo entity problem ?

Hello,

Is there a way to escape entity problems (such as &eacute;) in the .fo
file ?

We realize a first transformation to obtain a .fo file which is there
after
treated by FOP (Driver.run() ...).
Problem is that we generate this fo file with entities inside, so is
there
methods to pass an entity resolver to FOP transformer (as URIResolver
for classic transformer) ?


thanks.

Re: .fo entity problem ?

Posted by "J.Pietschmann" <j3...@yahoo.de>.
RAYMOND Romain wrote:
> Is there a way to escape entity problems (such as &eacute;) in the .fo
> file ?
> We realize a first transformation to obtain a .fo file which is there
> after
> treated by FOP (Driver.run() ...).
> Problem is that we generate this fo file with entities inside, so is
> there
> methods to pass an entity resolver to FOP transformer (as URIResolver
> for classic transformer) ?

I don't quite understand what your problem is.
If you generate the FO file with XSLT, it is not necessary
to generate entities in the result, in particular it is
not necessary to generate entities representing characters,
like &eacute;. This is especially mysterious as XSLT is not
designed to make it easy to put entities in the transformation
result.
The best way to deal with it is to avoid putting enities
in the FO. If you generate the file with XSLT, simply
remove all tricks which generate the entities. If you have
to put special characters into the result, you can always
resort to numerical character references, like &#201; for
&eacute;.

Furthermore a JAXP entity resolver is only responsible
for mapping a public and system ids to files. It does
not expand entitiy references, this is the task of the
parser itself. You have to supply a DTD with the entity
definitions to the parser in order to get the job done.

J.Pietschmann