I'm using curl at the command line on Linux to issue HTTP requests. The response bodies are printed to standard out, which is fine, but I can't see from the man page how to get curl to print the HTTP status code from the response (404, 403 etc). Is this possible?
|
feedback
|
|
This should work for you:
As an addition, to let cURL follow redirects (3xx statuses) add -L. | |||
|
feedback
|
|
If you want to see the header as well as the result you can also use -v:
| |||
|
feedback
|