New page function uses $_SERVER['HTTP_HOST'] instead of $_SERVER['SERVER_NAME'].