Skip to content
RedDragonWebDesign edited this page Sep 6, 2020 · 3 revisions

Hooks are used to get a function to run at a certain spot in the code.

Hooks are mainly used by plugins and themes. For functions used in core, just inline those.

Code for these is in classes/bthooks.php

btHooks::addHook

public function addHook($hookName, $function, $args = "") { }

btHooks::run

public function run($hookName) { }

List of hooks

  • breadcrumb
  • console_forms
  • display-member-app-components
  • form_richtexteditor
  • head
  • menu_item
  • newspost_show
  • profile_sections
  • search_results_display
  • search_results_init
  • search_results_query
  • twitch-plugin-display-card
  • worldclock-display
  • "console-".$modsAddMenusCID
  • "console-".$modsManageMenusCID
  • "donate_form-".$_GET['campaign_id']
  • "pluginsettings-".$pluginInfo['filepath']
  • $this->formName
Clone this wiki locally