Method |
Description |
|
__construct ( string $optionNamespace ) |
Creates a new TitanFramework object |
|
addCustomizerSaveFilter ( mixed $value, string $optionName, mixed $oldValue ) : mixed |
Adds a 'tf_save_option_{namespace}_{optionID}' filter to all Customizer options
which are just about to be saved |
|
createAdminPage ( array $settings ) : TitanFrameworkAdminPage |
Create a admin page |
|
createAdminPanel ( array $settings ) : TitanFrameworkAdminPage |
Create a admin page |
|
createCSS ( string $CSSString ) : void |
Generates style rules which can use options as their values |
|
createContainer ( array $settings ) : TitanFrameworkCustomizer | TitanFrameworkAdminPage | TitanFrameworkMetaBox |
Creates a container (e.g. admin page, meta box, customizer section) depending
on the type parameter given in $settings |
|
createCustomizer ( array $settings ) : TitanFrameworkCustomizer |
Create a customizer section |
|
createMetaBox ( array $settings ) : TitanFrameworkMetaBox |
Create a meta box |
|
createSampleContentPage ( array $settings ) : TitanFrameworkAdminPage |
Create a sample content only. |
|
createThemeCustomizerSection ( array $settings ) : TitanFrameworkCustomizer |
Create a customizer section |
|
deleteAllOptions ( ) : void |
Deletes ALL the options for the namespace. Even deletes all meta found in all posts. |
|
displayFrameworkError ( string $message, array | object $errorObject = null ) : void |
Displays an error notice |
|
generateCSS ( ) : string |
Gets the CSS generated |
|
getAllInstances ( ) : array |
Gets all active instances of Titan Framework |
|
getInstance ( string $optionNamespace ) : TitanFramework |
Gets an instance of the framework for the namespace |
|
getInternalAdminPageOption ( string $optionName, mixed $defaultValue = false ) : mixed |
Gets the admin page option that's loaded into the instance, used by the option class |
|
getOption ( string $optionName, integer $postID = null ) : mixed |
Get an option |
|
getOptions ( array $optionArray, integer $postID = null ) : array |
Gets a set of options. Pass an associative array containing the option names as keys and
the values you want to be retained if the option names are not implemented. |
|
getURL ( string $script, string $file ) : string |
Acts the same way as plugins_url( 'script', __FILE__ ) but returns then correct url
when called from inside a theme. |
|
loadAdminScripts ( string $hook ) : void |
Loads all the admin scripts used by Titan Framework |
|
rememberAllOptions ( TitanFrameworkOption $option ) : void |
Action hook on tf_create_option to remember all the options, used to ensure that our
serialized option does not get cluttered with unused options |
|
removeChildThemeOptions ( boolean $continueCreating, array $optionSettings ) : boolean |
Hook to the tf_create_option_continue filter, to check whether or not to continue
adding an option (if the option id was used in $titan->removeOption). |
|
removeOption ( string $optionName ) : void |
A function available ONLY to CHILD themes to stop the creation of options
created by the PARENT theme. |
|
saveInternalAdminPageOptions ( ) : array |
Saves all the admin (not meta & customizer) options which are currently loaded into this instance |
|
set ( string $setting, string $value ) : void |
Sets a value in the $setting class variable |
|
setInternalAdminPageOption ( string $optionName, mixed $value ) : boolean |
Sets the admin page option that's loaded into the instance, used by the option class. |
|
setOption ( string $optionName, mixed $value, integer $postID = null ) : boolean |
Sets an option |
|