/ Published in: PHP
Will return "dev" when it detect those syntax in the hostname dev. .local localhost 192.168
Expand |
Embed | Plain Text
define('ENVIRONMENT', preg_match('/(dev\.)|(\.local)|(localhost)|(192\.168)/', $_SERVER["HTTP_HOST"]) ? "dev" : "prod");
You need to login to post a comment.
