I am working on a project and trying to add one string to a resource file. I've read that the resource file in an MVC 3 project is converted to XML and the special characters are automatically escaped, but that doesn't seem to be the case. I have tried using / and using %xx hexidecimal ways to enter special characters, but none of those work correctly either. Without escaping some of these characters, the code errors out. Here is the string in the resource file I'm trying to fix:
Minimum of 6 letters, numbers, and special characters, no spaces. Special characters include: !, @, #, $, %, ^, &, (, ), -, _, =, +, {, }, |, /, ?.
As you can see at the end, I am including the usage of a number of special characters, but something in those characters is not liked when running the code. Any suggestions?
Use the HTML codes, I just tested it and it works fine, e.g. single apostrophe '
HTML code is ’
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