Added withCredentials parameter and passing it to xhr requests
Merge pull request #4124 from tkristiansen/with-credentials

Allow setting xhr.withCredentials