This is the part of the PHP script that I am compiling. Basically, the domain ($ domain1) is defined in the form and another message is displayed based on the response code from the server. However, I have problems with his work. A 3 digit response code is all that interests me.
Here is what I still have:
function get_http_response_code($domain1) { $headers = get_headers($domain1); return substr($headers[0], 9, 3); foreach ($get_http_response_code as $gethead) { if ($gethead == 200) { echo "OKAY!"; } else { echo "Nokay!"; } } }
source share