Adds timeout to URL request.

Originally recommended by user johnkdoe. Merged manually.