Sett & Charles - refactoring for running on apache
fixing wsgifunc() that was missing