Fixing JS encoding of " and \

Thanks @michaelficarra