The entity "nbsp" was referenced, but not declared
A user has reported an issue in Saxon/C PHP where they cannot reference the entity file to the Schema Validator. See report here: https://stackoverflow.com/questions/67935660/saxon-php-xml-schema-validation-with-entity-reference
#1 Updated by Michael Kay 3 months ago
I'm afraid O'Neil and I both barked up a lot of wrong trees before realising this is a simple user error. The DTD has
<?xml version="1.0" encoding="utf-8"?> <!DOCTYPE section [ <!ENTITY % ent1 SYSTEM "isonum.ent"> ]>
which declares a parameter entity
ent1 but never references it. If you want to expand the DTD to include the declarations contained in the parameter entity, you need to expand the parameter entity by referring to it, that is:
<?xml version="1.0" encoding="utf-8"?> <!DOCTYPE section [ <!ENTITY % ent1 SYSTEM "isonum.ent"> %ent1; ]>
With this change, the problem goes away.
I'm afraid we're getting rusty on remembering how DTDs work - we don't use them very often these days, partly because so many XML parsers don't support them fully.
Please register to edit this issue