March 08, 2012 12:55PM
I have "server_name *.domain.tld" in my config file and tried to get the correct virtual host the user connected to with the help of a php script but "$_SERVER['SERVER_NAME']" returned "*.domain.tld" instead of "something.domain.tld" when I connect to it.

When I use ".domain.tld" instead of "*.domain.tld" I get "domain.tld" as the hostname.

Is this is bug or how to get the real hostname the user connect to ?
Subject Author Posted

Possible bug in value of $server_name variable

Kaimei March 08, 2012 12:55PM

Re: Possible bug in value of $server_name variable

Francis Daly March 08, 2012 01:42PM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 306
Record Number of Users: 8 on April 13, 2023
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready