Jump to content

Making XML string safe


doubledee

Recommended Posts

I am building an XML string to send to another server.

 

The manual I am going off of says,

 

NOTE:

    * XML has a special set of characters that cannot be used in normal XML strings. These characters are:

      Special Character Equivalent

      & &

      < <

      > >

      " "

      ' &#39;

 

It goes on to say...

# To avoid problems with special characters, URLEncode special characters (example: ~ ! @ # % ^ &) before sending to the IS Gateway

# If you are using POST method, UTF-8 encoding must be used.

 

 

I am unsure of what to do based on the information above?!

 

It looks like I might want to use urlencode??

 

Also, maybe I need either htmlentities (or possibly htmlspecialchars)??

 

Please enlighten me (and help protect my data)!!  :)

 

Thanks,

 

 

 

Debbie

 

Link to comment
https://forums.phpfreaks.com/topic/232623-making-xml-string-safe/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • 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.