Replaced mysql access for settings multiple times by use of global constant