How to define your SITE_URL? $self = explode(‘/’, $_SERVER[‘PHP_SELF’]); array_pop($self); define(‘SITE_URL’, ‘http://’.$_SERVER[‘HTTP_HOST’].implode(‘/’, $self).’/’); define(‘IMG’, SITE_URL.’assets/uploads/’);