Method: ::getInstance()

SiteSettings is scoped to Controllers, public website document, and templates or views as $this->sitesettings. However, you may need to access it from other objects which do not have it pre-scoped.

The normal way to access SiteSettings would be to fetch its singleton object using SiteSettings::getInstance()


$sitesettings = SiteSettings::getInstance();
echo $sitesettings->getSetting('core' , 'email');

Example 2:

echo SiteSettings::getInstance()->getSetting('contact' , 'tel');

Contact Us

Address: 22a Fishergate York, YO10 4AB · Tel: 01904 636677 · Email: