White space entity is resolved when validating DTD but I wish it wouldn't
This should cover W3C XML Schema, Relax NG and DTD related problems.
-
- Posts: 1
- Joined: Tue Apr 26, 2022 2:07 pm
White space entity is resolved when validating DTD but I wish it wouldn't
When I validate an article against the JATS dtd in our validation service (JAVA, runs on a unix machine) that contains the following code:
I get this validation error:
entity that is the direct child of the mml:mrow element.
However, when I validate it against the same dtd in Oxygen, I get no error. It seems like the entity is resolved as a 'whitespace' and ignored.
While I get that this is the correct behaviour
I was wondering if there was a possibility to not resolve these whitespace entities so that we can replicate the behaviour of our server in Oxygen?
Thanks,
Zsofia
Code: Select all
<mml:math><mml:mrow><mml:mi>k</mml:mi><mml:mo>=</mml:mo><mml:mi>a</mml:mi> <mml:mo>.</mml:mo><mml:msub><mml:mi>c</mml:mi><mml:mi>p</mml:mi></mml:msub><mml:mo>.</mml:mo><mml:mi>ρ</mml:mi></mml:mrow></mml:math>
This is triggered by theThe content of element type "mml:mrow" must match "(copyright-statement*,copyright-year*,copyright-holder*,license*)". Children of type "character reference" are not allowed.
Code: Select all
 
However, when I validate it against the same dtd in Oxygen, I get no error. It seems like the entity is resolved as a 'whitespace' and ignored.
While I get that this is the correct behaviour

Thanks,
Zsofia
-
- Posts: 9431
- Joined: Fri Jul 09, 2004 5:18 pm
Re: White space entity is resolved when validating DTD but I wish it wouldn't
Hi Zsofia,
Validation of XML content against a schema/DTD is done on the resolved XML content which has already expanded the entity references to their text equivalents.
So Oxygen's behavior is correct and your server's validation service does not obey the XML specification.
https://www.w3.org/TR/xml/#include-if-valid
I'm afraid we do not have a setting to control this on Oxygen's side because our validation is correct.
Regards,
Radu
Validation of XML content against a schema/DTD is done on the resolved XML content which has already expanded the entity references to their text equivalents.
So Oxygen's behavior is correct and your server's validation service does not obey the XML specification.
https://www.w3.org/TR/xml/#include-if-valid
I'm afraid we do not have a setting to control this on Oxygen's side because our validation is correct.
Regards,
Radu
Radu Coravu
<oXygen/> XML Editor
http://www.oxygenxml.com
<oXygen/> XML Editor
http://www.oxygenxml.com
Jump to
- Oxygen XML Editor/Author/Developer
- ↳ Feature Request
- ↳ Common Problems
- ↳ DITA (Editing and Publishing DITA Content)
- ↳ SDK-API, Frameworks - Document Types
- ↳ DocBook
- ↳ TEI
- ↳ XHTML
- ↳ Other Issues
- Oxygen XML Web Author
- ↳ Feature Request
- ↳ Common Problems
- Oxygen Content Fusion
- ↳ Feature Request
- ↳ Common Problems
- Oxygen JSON Editor
- ↳ Feature Request
- ↳ Common Problems
- Oxygen PDF Chemistry
- ↳ Feature Request
- ↳ Common Problems
- Oxygen Feedback
- ↳ Feature Request
- ↳ Common Problems
- Oxygen XML WebHelp
- ↳ Feature Request
- ↳ Common Problems
- XML
- ↳ General XML Questions
- ↳ XSLT and FOP
- ↳ XML Schemas
- ↳ XQuery
- NVDL
- ↳ General NVDL Issues
- ↳ oNVDL Related Issues
- XML Services Market
- ↳ Offer a Service