-
Notifications
You must be signed in to change notification settings - Fork 2
Functions
In the root of our custom theme folder is the usual functions.php. This file requires the various function files in the includes/ folder.
There are three files that define some base functions and settings that are common to just about every project.
-
om-configure.phpThis file contains several functions that are activated through WordPress filters and actions to customise various settings.
-
om-dashboard.phpThis file contains functions developed to modify the WordPress Dashboard to assist our clients once the site is turned over. Things like custom WordPress alerts, etc.
-
om-functions.phpThis file has functions for common needs when developing a custom theme.
These files should generally not need to be editing. If editing is required, remember to file an issue or pull request with the change.
The files beginning with theme- are files that are used as a starting point for the custom theme. They contain some helpful starting points but can be edited as needed. If certain functions are consistently being added to theme-functions they should be considered for addition to om-functions.
-
theme-functions.phpThis file contains the CSS & JS registering functions to include theme assets appropriately using
get_header()and/orget_footer()functions. Any other functions can be added to it as needed. -
theme-require-plugins.phpThis file contains an array of plugins that can be marked as "required" and will trigger an alert in the WordPress Dashboard if not installed/activated. Some likely plugins are included, and the list can be edited as required.