Bug Fix for Apache 2.x user running mod_vhost_alias

Replaced $_SERVER['DOCUMENT_ROOT'] with str_replace($_SERVER['SCRIPT_NAME'], '', $_SERVER['SCRIPT_FILENAME']) to fix bug with vhost_alias in Apache 2.x