-
Notifications
You must be signed in to change notification settings - Fork 16
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Support namespaces #2
Comments
There is no expectation that XML, it its most generic senses as a host language, use prefixed attributes. Test 0330 for XML does not contain namespaces RDFa attributes (see http://rdfa.info/test-suite/test-cases/rdfa1.1/xml/0330.xml). Green Turtle passes the test suite and, in particular, this test. It does not support the ability to process host languages where the attributes are in the XHTML namespace. Although that feature could be added, it isn't planned at this time. |
Might be a misunderstanding. I just used Test 0330 as an arbitrary example to introduce a namespace. I was referring to the following sentence in the "RDFa Core 1.1 - Second Edition" document: "When a Host Language does not use the attributes in 'no namespace', they must be referenced via the XHTML Namespace (http://www.w3.org/1999/xhtml)." But your summary seems to nail it down: while the specification allows namespaces, Green Turtle does not support them, yet. Thanks. |
Actually, the specification says that "When a Host Language does not use the attributes in 'no namespace' ..." and XML, as a generic host language, allows for attributes in the no namespace. As such, the clause does not apply. If there was an XML vocabulary that forbid them or forbid any extra attributes without a namespace, then you would want a processor that supported such a mode. For example, I couldn't add RDFa attributes to the XProc vocabulary because it forbids any attributes without a namespace except its own. As such, to add RDFa to XProc, I would need to use the XHTML namespace with the attributes. As such, the Green Turtle processor can't process such a situation. As I said, it would be possible to add that support. In RDFaProcessor.js you would have to override setContext() to detect the vocabulary. Unfortunately, the code would need to be refactored to use a table of attribute namespaces as the names are just literals in the various places. Not a huge amount of work but I can't get to this now. I'll keep this open because such refactoring should be done anyway. I'd be happy to accept a patch. ;) |
Description: The library doesn't seem to handle RDFa if it's not in the default name space.
Version: Latest (today / 1.3.0)
Steps that will reproduce the problem?
What is the expected result?
Test should pass.
What happens instead?
Test fails.
Possible workaround:
?
Any additional information:
The text was updated successfully, but these errors were encountered: