This has nothing to do with Unicode characters and anything related to removing XML.
As stated in the XML standard that you are associated with, XML defines only 5 standard objects:
- <represents "<";
- > represents ">";
- & presents "&";
- & APOS; presents "'";
- " presents '' '.
All other objects (e.g. 🏫 ) are not valid in XML unless you explicitly define them.
However, there is a simple way out of this situation. The problem with this object is that it contains an ampersand that is NOT escaped, which makes it incompatible with XML. You just need to avoid this, and everything is in order with the world.
<add key="SenderName" value="&#x1f3eb; Mr Mooo"/>
Now your application will receive the raw string you want: 🏫 Mr Mooo 🏫 Mr Mooo , when you extract it from the configuration file, and then you can pass it to the view.
source share