View Issue Details

IDProjectCategoryView StatusLast Update
0008420Multi Theft Auto : San AndreasScriptingpublic2014-08-04 18:01
ReporterCheez Assigned ToJusonex  
Status resolvedResolutionfixed 
Target Version1.4.1Fixed in Version1.4.1 
Summary0008420: Cannot add CDATA tags using xmlNodeSetValue(node), node:setValue() or node.value

The <, > and & characters are illegal in XML and the must be escaped using CDATA tags, but unfortunately, when you try to do node.value = "<![CDATA[VALUE]]>", inside the XML file, the < and the > get replaced with < and > like this:
This way you can't add CDATA tags using xmlNodeSetValue(node), node:setValue() or node.value.
I made a workaround using file functions and a pattern(string:gsub("(<)(!%[CDATA%[)(.-)(%]%])(>)","<%2%3%4>")) for replacing those character codes with < and >, but I think this should be fixed.

NOTE: The same thing applies to the ampersand.

Additional Information

List of converted characters:
< = <

= >
& = &

TagsNo tags attached.



2014-08-02 12:36

viewer   ~~0021621

It looks like the character codes got converted to characters:
< = & lt;

= & gt;
& = & amp;
Remove the spaces.


2014-08-04 11:37

administrator   ~~0021658

What do you think of a new parameter named "useCDATA"?


2014-08-04 15:02

viewer   ~~0021660

Last edited: 2014-08-04 15:03

That would be ok, but I think that a parameter like convertIllegalCharacters would be better, if it's possible.


2014-08-04 18:01

administrator   ~~0021661

Fixed in

Issue History

Date Modified Username Field Change