I tried wrapping quotes with slashes and got the same result.
This response will be JSON encoded. The router can send back multiple transactions within a single response enclosed in an array. If the request was a form post and it was an upload the response will be sent back as a valid html document with the following content:
<html><body><textarea>{YOUR JSON RESPONSE HERE}</textarea></body></html> " must be back-slashed because the textarea will convert them to actual quotes. Therefore you must do a regular expression (/”/, ”\””)