Skip to content
This repository has been archived by the owner on Aug 21, 2023. It is now read-only.

Escaping XML entities on strings #6

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

joshmcarthur
Copy link

First of all, thanks heaps for porting AWS to a usable version of rails - it has really saved me some time getting Rails talking to a SOAP API.

This may be a slightly contentious point, but I found I was having problems using AWS since it was not escaping XML entities - specifically, the & symbol.

My fix is really simple - to escape any HTML characters in a string member of a struct, by wrapping CGI.escapeHTML around the value.to_s in the casting.rb file - which will of course escape HTML any time a string member is being outputted, which in turn should result in valid and well-formed XML being produced.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant