I had created the xml document with xml version="1.0".
In that document I need to use the greater than symbol >
and less than symbol <
.
How should I include those symbols? It's not working.
>
and <
are not working for me.
Is there any special encoder for this?
You will have to use XML escape characters: " to " ' to ' < to < > to > & to & Google escaping characters in XML for more information.
Just < and > . If you need an 'equals', simply append a = character.
The only illegal characters are & , < and > (as well as " or ' in attributes, depending on which character is used to delimit the attribute value: attr="must use " here, ' is allowed" and attr='must use ' here, " is allowed' ). They're escaped using XML entities, in this case you want & for & .
Open an XML document in the text editing mode, right click inside it and there is a new menu item "Determine Complex Layout Chars".
You need the Character Entity References
< = <
> = >
You can try to use CDATA to put all your symbols that don't work.
An example of something that will work in XML:
<![CDATA[ function matchwo(a,b) { if (a < b && a < 0) { return 1; } else { return 0; } } ]]>
And of course you can use <
and >
.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With