Parsing to_xml respond_to with Javascript

Have you considered using to_json?