Jump to content

Apostrophe character masking - can't figure out what this is!


JFlame

Recommended Posts

I'm having trouble with XML that is generated from user inputted data.

 

In some cases, it seems that folks are importing (via an import mechanism) data that contains apostrophes, but not regular apostrophes.  Example: "you're", "we've", "JFlame's", etc.  The problem is the character they are importing does not match the "  '  " character, so I'm having trouble escaping it. 

 

Honestly, it's never a problem that this character is being used, until it comes to XML.  XML hates this thing!  Even putting it in a !CDATA[ construct will make the XML bad. 

 

Let's see if I can paste an example here:  ’

 

How do I deal with that little guy in XML?  I have a few options, if I can figure out how to fix it at data import/upload then I can probably do that, but best is to mask it in the XML as it is being generated. 

 

Any ideas?

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.