by R.T. Brown.
The use of an envirnment variable for wwwroot is appealing to me because of dynamically created instances with in a cloud environment.
CFG->wwwroot = 'http://' . $_SERVER['HTTP_HOST'] . '';
Host names change as you add and substract servers. Is this not a valid use case / reason to use this convention?