Ajax: use anchor tag for parsing urls

This PR changes the Ajax URL parsing from using a regex to using an anchor tag. This should be simpler and more reliable.

Fixes https://github.com/jquery/jquery/issues/1875
/cc @dmethvin
I wasn't sure if this should just fail closed, or cancel the request. If the URL is malformed, the request will end up failing either way...