Using cmd curl to debug web pages

Hi, sometimes we need to check web page status via curl cmd. I want to show you some trics to get more readable output, and pass http basic authentication.


// This code will show you html output of the page. It is not very helpful in most cases.

// In cases when the website serve different websites versions on Host header basis can be used this request.
curl -skIl --verbose --header '' ''

// If website is http password protected we can use example below, where -u option provide login and pasword
curl -u user:pass -skIl --verbose --header '' ''

// If some data should be passed in request items[0]=335:
curl -u user:pass --data "items%5B0%5D=335"{some-id}

curl -u user:pass --data "items%5B0%5D=335&items%5B0%5D=336"{some-id}