Open johannes-titz opened 5 months ago
Found the problem: <0.001 cannot be processed because it contains <
This is what you tried to tell me yesterday, I believe.
Okay, I found a solution for my specific case; I just use HTMLdecode(hex=F, decimals=F), which in my case leaves < as is (
is translated, but not stuff like -
). Not sure though how to handle this in general. But in any case it would be nice to get a more meaningful error message, indicating that <0.001 is the problem.
Almost looks like qti is fine with decimal codes (e.g. -
) but not with named codes (
)?
yea, decimal works
Okay, my suggestion: translate < and > manually to decimal, then call HTMLdecode. Are there any other characters we need to take care of?
i am working on solution
I finally did it, but I don't like what I got. I transfer content of XML into HTML (it encode entities). The problem is that html allows tags without closing
, but it can lead to further mistakes, when a creator uses some functions to build html chunks (like you did with tables).
I believe we settled on: the user is responsible for producing correct XML/XHTML. We might want to mention this in the docs though.
I am working with the low level functions and experience the following problem:
gives:
Error in read_xml.raw(charToRaw(enc2utf8(x)), "UTF-8", ..., as_html = as_html, : StartTag: invalid element name [68]
How can I debug this? Obviously, some tag is incorrect, but the message is not very informative. Can we output the actual tag? What is 68 referring to?
The table is automatically created via another package, it is already HTMLdecoded.