问题
Is there a way to separate the hostname and path when using cURL? I would like to make a request to the server itself, not on a particular resource, as described below by IETF:
The four options for Request-URI are dependent on the nature of the request. The asterisk "*" means that the request does not apply to a particular resource, but to the server itself, and is only allowed when the method used does not necessarily apply to a resource. One example would be
OPTIONS * HTTP/1.1
http://tools.ietf.org/html/rfc2616#section-5.1.2
Similar to this question: https://stackoverflow.com/q/12323445/594696
来源:https://stackoverflow.com/questions/16423999/separate-hostname-and-path-in-curl