Various character escaping changes