added check for $CFG->customHomepage