Because of the infamous IIS bugs concerning the "Location" redirect header, we have to use the "Refresh" header instead.
So, I would like to know the best method to programmatically detect if PHP script is running under IIS.
Currently used method is DIRECTORY_SEPARATOR !== '/', but obviously Apache and other servers under Windows are uncorrectly recognized as IIS.
I thought about:
strpos($_SERVER['SERVER_SOFTWARE'], 'Microsoft-IIS') !== false
... but this element corresponds to the "Server" header of the HTTP response, and it may have been removed by various means.
Any ideas of robuster methods?