[reportlab-users] Redefining the place where a DTD is searched
in pyRXP
John J. Lee
jjlee at reportlab.com
Thu Feb 10 07:23:49 EST 2005
Something like this:
def eoCB(s,targets=['blah.dtd'],dtdDir=dtdDir):
bn = os.path.basename(s)
if os.path.basename(s) in targets:
fn = os.path.join(dtdDir,bn)
if rl_isfile(fn):
return fn, open(fn,'t')
return s
John
On Thu, 10 Feb 2005, Marco Bizzarri wrote:
> Hi all.
>
> I'm trying to validate a document using the pyRXP parser. I'm including
> a test file.
>
> What I would like to do is to state where the 'Segnatura.dtd' should be
> looked.
>
> I've tryied redefining the eoCB, but, as far as I understand, this is
> not called for the DTD definition.
>
> Any suggestion (some pointer to the code is also accepted) ?
>
> Regards
> Marco
>
More information about the reportlab-users
mailing list