why $host is allways set to header (if the header exists)? #890
Unanswered
szuwarek80
asked this question in
Q&A
Replies: 1 comment · 6 replies
-
If you use curl to test, you will find that only the host header has domain name information, so the $host variable comes from the host header. |
Beta Was this translation helpful? Give feedback.
6 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
if I call
curl --location 'https://my-host/test'
the
$host
is equal tomy-host
however if I call
curl --location 'https://my-host/test' --header 'Host: wp.pl'
the
$host
is queal towp.pl
I need to be aware of such a situation to have some special behaviour.
Am I able to find one that this happened ?
Beta Was this translation helpful? Give feedback.
All reactions