Total hooks: 63Undocumented hooks: 33
Type: action
Triggered when WP Hummingbird is totally loaded
Arguments: none
No description
Type: filter
Allow to filter a WP Hummingbird Metabox
Arguments: $meta_box, $this->slug, $this->page_id
$meta_box - arrayMeta box attributes
$meta_box
array
$slug - stringAdmin page slug
$slug
string
$page_id - stringAdmin page ID
$page_id
Type: action_reference
Arguments: array(&$this)
Arguments: $hide_footer
Arguments: $footer_text
Arguments: $this->tabs
Settings meta box.
Arguments: true, $item, 'styles'
Arguments: true, $item, 'scripts'
Filter minification enqueued files items displaying
Arguments: true, $item, $type
$display - boolIf set to true, display the item. Default false
$display
bool
$item - arrayItem data
$item
$type - stringType of the current item (scripts|styles)
$type
Allows to enable/disable switchers in minification page
Arguments: $disable_switchers, $item, $type
$disable_switchers - arrayList of switchers disabled for an item ( include, minify, combine)
$disable_switchers
$item - arrayInfo about the current item
Asset Optimization
Pass in caching type and value into a custom function.
Arguments: array('expiry_times' => $sanitized_expiry_times)
$args - array{ Array of selected type and value. @type string $type Type of cached data, can be one of following: javascript, css, media or images. @type array $sanitized_expiry_times Set expiry values (for example, 1h/A3600), first part can be: [n]h for [n] hours (for example, 1h, 4h, 11h, etc), [n]d for [n] days (for example, 1d, 4d, 11d, etc), [n]M for [n] months (for example, 1M, 4M, 11M, etc), [n]y for [n] years (for example, 1y, 4y, 11y, etc), second part is the first part in seconds ( 1 hour = 3600 sec). }
$args
javascript
css
media
images
[n]h
[n]d
[n]M
[n]y
Triggered when Hummingbird Admin is loaded
Arguments: array('stylesheet' => get_stylesheet_directory() . '/wphb/', 'template' => get_template_directory() . '/wphb/', 'plugin' => WPHB_DIR_PATH . 'core/pro/modules/reporting/templates/')
Arguments: array('reporting-cron' => 'Cron', 'cleanup-cron' => 'Database Cleanup', 'uptime-reports' => 'Reports')
Filters the activation of a module
Arguments: true
$active - booleanif the module is active or not
$active
boolean
Fires after the database cleanup task.
Arguments: $type, $items
$type - stringData type that was cleared from the database. Can return following values: all, revisions, drafts, trash, spam, trash_comment, expired_transients, transients.
$items - intNumber of items that was cleared from the database for the selected data type.
$items
int
Filters the list of allowed comment types for retrieving avatars.
Arguments: array('comment')
$types - arrayAn array of content types. Default only contains 'comment'.
$types
This filter is documented in wp-includes/link-template.php
Arguments: $args, $id_or_email
Arguments: $results
If caching for logged-in users, we need to set the cache file extension to .php and add die(); in file header, to prevent phishing attacks.
Arguments: 'Do not cache, blocked by filter'
Arguments: $content
Support for custom terms.
Arguments: array()
2. Check if the files are there?
Arguments: $messages
Filter the resource (blocked or not)
Arguments: false, $handle, $this->type, $url, null
Filter the resource (minify or not)
Arguments: false, $handle, $this->type, $url
Filter the resource (combine or not)
Filter the resource (defer or not)
Filter the resource (inline or not)
Function that will get files minified
<p>The callback should return WP_Error or array with the file details: { 'file' => absolute file path if the file is saved locally }</p>
Arguments: array('WP_Hummingbird_Module_Minify_Group', 'process_remote_files')
Insert the new file in posts table.
<p>The ID argument acts as an insurance that a post with the same name does not exist already. No two posts should have a similar hash, unless it is two exactly same files. In that case we will use one post for both.</p> <p>In any case, if the above get_posts() does not find any posts, an ID = 0 will create a new post.</p>
Arguments: MONTH_IN_SECONDS
Arguments: $filename, $file['response']
Arguments: $filename, $file['response'], $upload
Filter the minification errors
Arguments: get_option('wphb-minification-errors', $default)
Arguments: $error, $handle, $type
Arguments: $is_cloudflare
Filter the resource (move to footer)
Arguments: false, $handle, $type, $wp_dependencies->registered[$handle]->src
Fires after getting the latest report.
Arguments: $results->data
$report - objectObject with report data.
$report
object
Filters the modules slugs list
Arguments: array('minify' => 'Minify', 'gzip' => 'Gzip', 'caching' => 'Caching', 'performance' => 'Performance', 'uptime' => 'Uptime Monitoring', 'smush' => 'Smush', 'cloudflare' => 'Cloudflare', 'gravatar' => 'Gravatar Caching', 'page_cache' => 'Page Caching', 'advanced' => 'Advanced Tools', 'rss' => 'RSS Caching')
Arguments: $type
Filter the default settings.
<p>Useful when adding new settings to the plugin</p>
Arguments: $defaults
Previous version of performance reports had week days (Monday-Sunday) for month schedule, now it's replaced with 1-28 days.
DOCUMENT_ROOT does not always store the correct path. For example, Bedrock appends /wp/ to the default dir.
<p>So if the source is a URL, we can safely use DOCUMENT_ROOT, else see if ABSPATH is defined.</p>
Arguments: $path, $src
Arguments: $cap
Current user @var WP_User $user
Arguments: $days
Arguments: array('00')
Arguments: $time
Arguments: $data
Arguments: false
Arguments: $module->get_server_code_snippet($server_type, $expiry_times), $server_type, $module