A standard theme always required some configuration, for example Logo change, Menu options, Slide Customization etc. For example see below options for Rainbow theme:
If you see the definition of Rainbow, there we have point themesettings.xml like below. This file is exists in definition folder of theme.
<settings>themesettings.xml</settings>
This is basically an implementation of Site Setting module of appRain. Once we add this file the Setting link in Admin Panel (See above Screen capture) creates automatically. See below example of a definition file.
<SiteSettings>
<sections>
<base name="themesettings">
<title>Theme Setting</title>
<admin_tab>developer</admin_tab>
</base>
<groups>
<group>
<base name="logooptions">
<title>Logo Options</title>
<acl>
<ugroup>superadmin</ugroup>
</acl>
</base>
<selections>
<selection>
<title>Website Logo</title>
<name>site_logo</name>
<hints>Webste Header Logo</hints>
<default></default>
<type>fileTag</type>
</selection>
</selections>
</group>
<group>
<base name="common">
<title>Common Settings</title>
<acl>
<ugroup>superadmin</ugroup>
</acl>
</base>
<selections>
<selection>
<title>Disable Quick Links</title>
<name>disable_quick_links</name>
<type>radioTag</type>
<default>No</default>
<options>
<option value="Yes">Yes</option>
<option value="No">No</option>
</options>
</selection>
<selection>
<title>Disable Footer</title>
<name>rainboo_disable_footer</name>
<type>radioTag</type>
<default>No</default>
<options>
<option value="Yes">Yes</option>
<option value="No">No</option>
</options>
</selection>
</selections>
</group>
<group>
<base name="slideshow">
<title>Slideshow Options</title>
<acl>
<ugroup>superadmin</ugroup>
</acl>
</base>
<selections>
<selection>
<title>Slide Render Type</title>
<name>rainboo_slide_position</name>
<type>radioTag</type>
<default>defaultslideshow</default>
<options>
<option value="defaultslideshow">Theme Default</option>
<option value="fromcomponent">Component Library</option>
</options>
</selection>
</selections>
</group>
</groups>
</sections>
</SiteSettings>
You can add or remove fields as required for more information please see Site Setting Manual.
Setting value can retrieve by following API
App::Config()->Setting([FIELD NAME],[DEFAULT VALUE]);
For example:
echo App::Config()->Setting('site_logo');
echo App::Config()->Setting('rainbow_slideshow','Yes');
You can use below API to get list of all settings
$arr = App::Config()->siteInfo(); // Return Array