Added an option to auto-detect XmlHttpRequests based on server headers