Each controller has a set of actions that can be called from inside your plugin these actions can be used to insert HTML into a view, call a procedure, override or append data or alter a view.
To call a action from inside a plugin simply use the add_action(action string, function string) function, this function has two parameters both are strings, the first is the action name (a list of actions can be found below) the second is the function in your plugin that you wish to call. If a action has a parameter your plugin function should return a parameter.
Globals - All controllers
Action Name | Params | Param type | Description |
---|---|---|---|
*.header | header | string | Sets the header view |
*.nav_data | nav_data | array | Contains navigation data |
*.navbar | navbar | string | Sets the navigation bar view |
*.post_vars | post_vars | array | Contains the controllers post variables |
*.data | data | array | Contains the content views data |
*.view | view | string | Sets the content view |
*.footer | footer | string | Sets the footer view |
*.pre | Allows insertion of html directly after the <body> tag of the view | ||
*.post | Allows insertion of html directly before the </body> tag of the view | ||
upload_file.success | file_data | array | called directly after a successful file upload |
Home Controller
Action Name | Params | Param type | Description |
---|---|---|---|
home.header | header | string | Sets the header view |
home.nav_data | nav_data | array | Contains navigation data |
home.navbar | navbar | string | Sets the navigation bar view |
home.post_vars | post_vars | array | Contains the controllers post variables |
home.data | data | array | Contains the content views data |
home.view | view | string | Sets the content view |
home.footer | footer | string | Sets the footer view |
home.pre | Allows insertion of html directly after the <body> tag of the view | ||
home.post | Allows insertion of html directly before the </body> tag of the view |
Screens Controller
Action Name | Params | Param type | Description |
---|---|---|---|
screens.header | header | string | Sets the header view |
screens.nav_data | nav_data | array | Contains navigation data |
screens.navbar | navbar | string | Sets the navigation bar view |
screens.post_vars | post_vars | array | Contains the controllers post variables |
screens.data | data | array | Contains the content views data |
screens.view | view | string | Sets the content view |
screens.footer | footer | string | Sets the footer view |
screens.pre | Allows insertion of html directly after the <body> tag of the view | ||
screens.post | Allows insertion of html directly before the </body> tag of the view | ||
screens.remove_screen | screen | Called once a screen has been removed | |
screens.wipe_screen | screen | Called once a screen wipe has been requested |
Groups Controller
Action Name | Params | Param type | Description |
---|---|---|---|
groups.header | header | string | Sets the header view |
groups.nav_data | nav_data | array | Contains navigation data |
groups.navbar | navbar | string | Sets the navigation bar view |
groups.post_vars | post_vars | array | Contains the controllers post variables |
groups.data | data | array | Contains the content views data |
groups.view | view | string | Sets the content view |
groups.footer | footer | string | Sets the footer view |
groups.pre | Allows insertion of html directly after the <body> tag of the view | ||
groups.post | Allows insertion of html directly before the </body> tag of the view |
Layouts Controller
Action Name | Params | Param type | Description |
---|---|---|---|
layouts.header | header | string | Sets the header view |
layouts.nav_data | nav_data | array | Contains navigation data |
layouts.navbar | navbar | string | Sets the navigation bar view |
layouts.post_vars | post_vars | array | Contains the controllers post variables |
layouts.data | data | array | Contains the content views data |
layouts.view | view | string | Sets the content view |
layouts.footer | footer | string | Sets the footer view |
layouts.pre | Allows insertion of html directly after the <body> tag of the view | ||
layouts.post | Allows insertion of html directly before the </body> tag of the view | ||
layout.remove_layout | layout | Called after a layout is removed | |
layout.disabled_layout | layout | Called after a layout is disabled | |
layout.enabled_layout | layout | Called after a layout is enabled |
Jukebox Controller
Action Name | Params | Param type | Description |
---|---|---|---|
jukebox.header | header | string | Sets the header view |
jukebox.nav_data | nav_data | array | Contains navigation data |
jukebox.navbar | navbar | string | Sets the navigation bar view |
jukebox.post_vars | post_vars | array | Contains the controllers post variables |
jukebox.data | data | array | Contains the content views data |
jukebox.view | view | string | Sets the content view |
jukebox.footer | footer | string | Sets the footer view |
jukebox.pre | Allows insertion of html directly after the <body> tag of the view | ||
jukebox.post | Allows insertion of html directly before the </body> tag of the view | ||
jukebox.song_added | song | When a song has been added this action it triggered | |
jukebox.song_removed | song | When a song has been removed this action it triggered | |
jukebox.song_disabled | song | When a song has been disabled this action it triggered | |
jukebox.song_enable | song | When a song is enabled this action it triggered |
Users Controller
Action Name | Params | Param type | Description |
---|---|---|---|
users.header | header | string | Sets the header view |
users.nav_data | nav_data | array | Contains navigation data |
users.navbar | navbar | string | Sets the navigation bar view |
users.post_vars | post_vars | array | Contains the controllers post variables |
users.data | data | array | Contains the content views data |
users.view | view | string | Sets the content view |
users.footer | footer | string | Sets the footer view |
users.pre | Allows insertion of html directly after the <body> tag of the view | ||
users.post | Allows insertion of html directly before the </body> tag of the view | ||
users.remove_user | user | Called after a user has been removed |
Plugins Controller
Action Name | Params | Param type | Description |
---|---|---|---|
plugins.header | header | string | Sets the header view |
plugins.nav_data | nav_data | array | Contains navigation data |
plugins.navbar | navbar | string | Sets the navigation bar view |
plugins.post_vars | post_vars | array | Contains the controllers post variables |
plugins.data | data | array | Contains the content views data |
plugins.view | view | string | Sets the content view |
plugins.footer | footer | string | Sets the footer view |
plugins.pre | Allows insertion of html directly after the <body> tag of the view | ||
plugins.post | Allows insertion of html directly before the </body> tag of the view |
Settings Controller
Action Name | Params | Param type | Description |
---|---|---|---|
settings.header | header | string | Sets the header view |
settings.nav_data | nav_data | array | Contains navigation data |
settings.navbar | navbar | string | Sets the navigation bar view |
settings.post_vars | post_vars | array | Contains the controllers post variables |
settings.data | data | array | Contains the content views data |
settings.view | view | string | Sets the content view |
settings.footer | footer | string | Sets the footer view |
settings.pre | Allows insertion of html directly after the <body> tag of the view | ||
settings.post | Allows insertion of html directly before the </body> tag of the view | ||
settings.save_settings | Called after settings have been saved |
Sync controller
Action Name | Params | Param type | Description |
---|---|---|---|
sync_register.pre | Allows execution of code when a sync registration is initialised | ||
sync_register.result | result | array | Contains and allows manipulation the registration results |
sync_register.post | Allows execution of code when a sync registration is finished | ||
sync_check.pre | Allows execution of code when a sync is initialised | ||
sync_check.result | result | Array | Contains and allows manipulation the sync results |
sync_check.post | Allows execution of code when a sync is finished |
Email Model
Action Name | Params | Param type | Description |
---|---|---|---|
email.message | Allows modification of the email message prior to sending | ||
email.sent | debug | Called after an email is sent passes the debug trace for the email |