Klp rectified

Few changes with settings, so that they work with apache. Couple of bug fixes