Welcome Guest, Not a member yet? Register   Sign In
database error using virtual hosts
#5

[eluser]CroNiX[/eluser]
I check for production and testing server, and default to development. Then that won't matter, and it's also useful if you have multiple developers.

Code:
switch($env)
{
  case 'www.domain.com':
    define('ENVIRONMENT', 'production');
    break;
  case 'dev.domain.com':
    define('ENVIRONMENT', 'testing');
    break;
  default:
    define('ENVIRONMENT', 'development');
    break;
}


Messages In This Thread
database error using virtual hosts - by El Forum - 12-16-2013, 07:36 PM
database error using virtual hosts - by El Forum - 12-26-2013, 03:12 PM
database error using virtual hosts - by El Forum - 12-26-2013, 03:35 PM
database error using virtual hosts - by El Forum - 12-26-2013, 03:50 PM
database error using virtual hosts - by El Forum - 12-26-2013, 04:35 PM



Theme © iAndrew 2016 - Forum software by © MyBB