├── index.html ├── beehive---google-analytics-hooks-doc.html ├── wpmu-dev-dashboard-hooks-doc.html ├── hummingbird-hooks-doc.html ├── smartcrawl-seo-hooks-doc.html ├── defender-hooks-doc.html ├── smush-hooks-doc.html ├── snapshot-hooks-doc.html ├── shipper-hooks-doc.html └── branda-hooks-doc.html /index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 |
Total hooks: 14Undocumented hooks: 14
Type: filter
No description
Arguments: true
Type: action
Arguments: ''
Arguments: 'b'
Arguments: $options, $network, $this->options_name
Arguments: 0
Arguments: '640050123521-r5bp4142nh6dkh8bn0e6sn3pv852v3fm.apps.googleusercontent.com'
Arguments: 'wWEelqN4DvE2DJjUPp-4KSka'
Arguments: 'AIzaSyBGtoZs_e4AgakpuM1q04KdwfBxkt7TQv8'
Arguments: $this->cache_timeout
Arguments: $instance['title']
Total hooks: 39Undocumented hooks: 17
Run custom initialization code for the UI module.
Arguments: $this
Arguments: $this->page_urls->remote_site . 'wp-login.php?redirect_to=' . rawurlencode($plugin_url) . '#signup', $project_id
Use this action to register custom sub-menu items.
<p>The action is called before each of the default submenu items is registered, so other plugins can hook into any position they like by checking the action parameter.</p>
Arguments: $this, 'plugins'
Arguments: 'support'
Arguments: 'tools'
Arguments: 'settings'
Arguments: 'end'
Custom hook to display own notifications inside Dashboard.
Arguments: none
Output some content before the template is loaded, or modify the variables passed to the template.
Arguments: $data
Output code or do stuff after the template was loaded.
Registers a Hub api action and callback for it
Arguments: array()
$action -
$action
$callback - callableThe name of the function you wish to be called.
$callback
callable
Filter output SUI whitelabel-ing
Arguments: $output
Run custom initialization code for the Site module.
Arguments: 'The Upfront parent theme is missing!Please install it to use your Upfront child themes', 'Install Upfront'
Arguments: $message, $cta
Filter Plugin Pages Map to be whitelabel-ed
<p>This should return array, with <code>key</code> WP_Screen.base, and <code>value</code> is array with <code>callable</code>, it's queue, first registered, first executed</p> <p>Callable function should accept array as parameter, Within this array there will be <code>page_base</code>, <code>settings</code>.</p> <p>Callable is executed within <code>admin_head-$hook_suffix</code> with <code>999</code> as priority, which expected to be last-executed</p> <p>If callable are multiple then it works as queue, First registered, First executed, means <code>$callabels[0]</code> will called first</p> <p>If need to attach into another hook example <code>admin_print_footer_scripts</code> then attach it inside its callable function</p> <p>Using this filter encouraged, to avoid race condition, in case plugin hooks is loaded first before Dash plugin initiated, which will be needed as <code>WPMUDEV_Dashboard::$site->get_whitelabel_settings();</code> must be initiated</p>
Arguments: $plugin_pages
$plugin_pages - array
$plugin_pages
array
Arguments: array('dashboard', 'dashboard-network')
Run custom initialization code for the API module.
Arguments: $secure, $user_id
Arguments: $res
Collect extra data from individual plugins.
Arguments: $extra
$extra - stringDefault extra data is an empty string.
$extra
string
Arguments: $extra, $pid
Allows modification of the plugin data that is sent to the server.
Arguments: $projects
$projects - arrayThe whole array of project details.
$projects
Allows excluding certain projects from update notifications.
<p>Basically just check the ID and return true if you want to silence updates.</p> <p>Filter result is only used if the remote-project <code>autoupdate</code> attribute does not have value 2.</p>
Arguments: false, $pid
$flag - boolDefaults to false, return true to silence.
$flag
bool
$pid - intThe WDP ID of the plugin/theme
$pid
int
Run custom initialization code for the Notice module.
Arguments: true, $msg
Arguments: 'info', $msg
Arguments: array(119)
Custom code can be executed after Dashboard is initialized with the default settings.
Total hooks: 63Undocumented hooks: 33
Triggered when WP Hummingbird is totally loaded
Allow to filter a WP Hummingbird Metabox
Arguments: $meta_box, $this->slug, $this->page_id
$meta_box - arrayMeta box attributes
$meta_box
$slug - stringAdmin page slug
$slug
$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
$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
$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
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.
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: false
Arguments: $module->get_server_code_snippet($server_type, $expiry_times), $server_type, $module
Total hooks: 99Undocumented hooks: 96
Arguments: $default_roles
Arguments: $this->options
If the user un-checks a checkbox and saves the post, the value for that checkbox will not be included inside $_POST array so we may have to delete the corresponding meta value manually.
Arguments: self::READABILITY_KINCAID
Arguments: array_filter($redirections)
Arguments: array_filter($types)
Arguments: $source
Arguments: $this->change_frequency, $this->get_location(), $this->get_priority(), $this->get_last_modified(), $this->get_images()
Arguments: $ignores
Arguments: 'google'
Arguments: 'google', false, $resp
Arguments: 'google', (bool) (200 === (int) wp_remote_retrieve_response_code($resp)), $resp
Arguments: 'bing'
Arguments: 'bing', false, $resp
Arguments: 'bing', (bool) (200 === (int) wp_remote_retrieve_response_code($resp)), $resp
Arguments: $priority
Arguments: $priority, $post
Arguments: $hero_image
Arguments: $title
Arguments: $description
Arguments: $result
Arguments: array_combine(apply_filters('wds-known_macros-keys', array_keys($replacements)), apply_filters('wds-known_macros-values', array_values($replacements)))
Arguments: array_keys($replacements)
Arguments: array_values($replacements)
Arguments: $replacement, $macro
Arguments: $can_access
Arguments: $this->is_dahsboard_active() && $this->has_dashboard_key()
Arguments: $installed
Arguments: !empty($key)
Arguments: $api_key
Arguments: $can_install
Arguments: apply_filters($this->get_filter('request'), $response, $verb)
Arguments: $response, $verb
Arguments: $expiry
Arguments: network_site_url()
Arguments: 'api'
Arguments: 'seo-audit/v1'
Arguments: 'seo-checkup/v1'
Arguments: $data, $this
Arguments: (string) trim(join(' 46 | ', $bits)), $post_id
Arguments: $name, $this->_user_id
Arguments: $name, $first, $last
Arguments: $url, $this->get_id()
Arguments: $this->title
Arguments: $this->description
Arguments: $images
Arguments: strpos($version, '11.') === 0
ptarchive settings are for custom post types only so let's remove the mappings for builtin post types
Arguments: 300
Arguments: $level
Arguments: $this->canonical
Arguments: $meta_value, $term, $taxonomy
Arguments: $capability
Checks if a define switch is toggled on
<p>Used in tests.</p>
Arguments: $result, $switch
$result - boolWhether the switch is turned on.
$result
$switch - stringSwitch name.
$switch
Arguments: trim(join(' ', $ret))
Arguments: $sitemap_url
Arguments: strpos($version, '2.12') === 0
Arguments: $image, $raw->ID, $player
Arguments: $image
Arguments: false, $post_id, $body
Arguments: $src, $post_id, $body
Arguments: '', $src, $post_id
Arguments: $this->_is_running
Arguments: $is_utf8_site
Arguments: home_url(), $status
Arguments: $post->post_content
Arguments: 'The content!'
Arguments: $this->content
Total hooks: 77Undocumented hooks: 60
Arguments: $post_vars
Arguments: $cf_ip
Arguments: $ret
Arguments: array('00', '30')
Arguments: array('apache' => 'Apache', 'litespeed' => 'LiteSpeed', 'nginx' => 'NGINX', 'iis' => 'IIS', 'iis-7' => 'IIS 7')
Arguments: $url
Arguments: plugin_basename(__FILE__), 'Defender', array('toplevel_page_wp-defender', 'toplevel_page_wp-defender-network'), array('after', '.sui-wrap .sui-header')
Arguments: plugin_basename(__FILE__), 'Defender', '/plugins/defender-security/', 'Get Secure!'->domain), '0cecf2890e'
Arguments: strftime('%I:%M %p', strtotime($time))
Arguments: 30000
loop through scanning steps, instance scan step as queue and process
Arguments: 128
When we processing the scan by ajax, clear all the which does the same job
Arguments: network_admin_url('admin.php?page=wdf-scan'), $email
Arguments: $params
Arguments: $settings->email_subject
Arguments: $email_content, $model
Arguments: $no_reply_email
Arguments: '+24 hours'
Arguments: $settings->last_seen
Arguments: $settings->last_sent
Arguments: network_admin_url('admin.php?page=wdf-hardener'), $email
Filters the error codes array for shaking the login form.
Arguments: $shake_error_codes
$shake_error_codes - arrayError codes that shake the login form.
$shake_error_codes
Enqueue scripts and styles for the login page.
Fires in the login page header after scripts are enqueued.
Filters link URL of the header logo above login form.
Arguments: $login_header_url
$login_header_url - stringLogin header logo URL.
$login_header_url
Filters the title attribute of the header logo above login form.
Arguments: $login_header_title
$login_header_title - stringLogin header logo title attribute.
$login_header_title
Filters the login page body classes.
Arguments: $classes, $action
$classes - arrayAn array of body classes.
$classes
$action - stringThe action that brought the visitor to the login page.
Fires in the login page header after the body tag is opened.
Filters the message to display above the login form.
Arguments: $message
$message - stringLogin message text.
$message
Filters the error messages displayed above the login form.
Arguments: $errors
$errors - stringLogin error message.
$errors
Filters instructional messages displayed above the login form.
$messages - stringLogin messages.
$messages
Fires in the login page footer.
hook into wordpress login, can't use authenticate hook as that badly conflict
Arguments: $redirect, isset($_REQUEST['redirect_to']) ? $_REQUEST['redirect_to'] : '', $user
Arguments: array('blogname' => 'Site Title'->domain), 'blogdescription' => 'Tagline'->domain), 'gmt_offset' => 'Timezone'->domain), 'date_format' => 'Date Format'->domain), 'time_format' => 'Time Format'->domain), 'start_of_week' => 'Week Starts On'->domain), 'timezone_string' => 'Timezone'->domain), 'WPLANG' => 'Site Language'->domain), 'siteurl' => 'WordPress Address (URL)'->domain), 'home' => 'Site Address (URL)'->domain), 'admin_email' => 'Email Address'->domain), 'users_can_register' => 'Membership'->domain), 'default_role' => 'New User Default Role'->domain), 'default_pingback_flag' => 'Default article settings'->domain), 'default_ping_status' => 'Default article settings'->domain), 'default_comment_status' => 'Default article settings'->domain), 'comments_notify' => 'Email me whenever'->domain), 'moderation_notify' => 'Email me whenever'->domain), 'comment_moderation' => 'Before a comment appears'->domain), 'require_name_email' => 'Other comment settings'->domain), 'comment_whitelist' => 'Before a comment appears'->domain), 'comment_max_links' => 'Comment Moderation'->domain), 'moderation_keys' => 'Comment Moderation'->domain), 'blacklist_keys' => 'Comment Blacklist'->domain), 'show_avatars' => 'Avatar Display'->domain), 'avatar_rating' => 'Maximum Rating'->domain), 'avatar_default' => 'Default Avatar'->domain), 'close_comments_for_old_posts' => 'Other comment settings'->domain), 'close_comments_days_old' => 'Other comment settings'->domain), 'thread_comments' => 'Other comment settings'->domain), 'thread_comments_depth' => 'Other comment settings'->domain), 'page_comments' => 'Other comment settings'->domain), 'comments_per_page' => 'Other comment settings'->domain), 'default_comments_page' => 'Other comment settings'->domain), 'comment_order' => 'Other comment settings'->domain), 'comment_registration' => 'Other comment settings'->domain), 'thumbnail_size_w' => 'Thumbnail size'->domain), 'thumbnail_size_h' => 'Thumbnail size'->domain), 'thumbnail_crop' => 'Thumbnail size'->domain), 'medium_size_w' => 'Medium size'->domain), 'medium_size_h' => 'Medium size'->domain), 'medium_large_size_w' => 'Medium size'->domain), 'medium_large_size_h' => 'Medium size'->domain), 'large_size_w' => 'Large size'->domain), 'large_size_h' => 'Large size'->domain), 'image_default_size' => '', wp_defender()->domain), '->domain), 'image_default_link_type' => '', wp_defender()->domain), '->domain), 'posts_per_page' => 'Blog pages show at most'->domain), 'posts_per_rss' => 'Syndication feeds show the most recent'->domain), 'rss_use_excerpt' => 'For each article in a feed, show'->domain), 'show_on_front' => 'Front page displays'->domain), 'page_on_front' => 'Front page'->domain), 'page_for_posts' => 'Posts page'->domain), 'blog_public' => 'Search Engine Visibility'->domain), 'default_category' => 'Default Post Category'->domain), 'default_email_category' => 'Default Mail Category'->domain), 'default_link_category' => '', wp_defender()->domain), '->domain), 'mailserver_url' => 'Mail Server'->domain), 'mailserver_port' => 'Port'->domain), 'mailserver_login' => 'Login Name'->domain), 'mailserver_pass' => 'Password'->domain), 'ping_sites' => '', wp_defender()->domain), '->domain), 'category_base' => 'Category base'->domain), 'tag_base' => 'Tag base'->domain), 'registrationnotification' => 'Registration notification'->domain), 'registration' => 'Allow new registrations'->domain), 'add_new_users' => 'Add New Users'->domain), 'menu_items' => 'Enable administration menus'->domain), 'upload_space_check_disabled' => 'Site upload space'->domain), 'blog_upload_space' => 'Site upload space'->domain), 'upload_filetypes' => 'Upload file types'->domain), 'site_name' => 'Network Title'->domain), 'first_post' => 'First Post'->domain), 'first_page' => 'First Page'->domain), 'first_comment' => 'First Comment'->domain), 'first_comment_url' => 'First Comment URL'->domain), 'first_comment_author' => 'First Comment Author'->domain), 'welcome_email' => 'Welcome Email'->domain), 'welcome_user_email' => 'Welcome User Email'->domain), 'fileupload_maxk' => 'Max upload file size'->domain), 'illegal_names' => 'Banned Names'->domain), 'limited_email_domains' => 'Limited Email Registrations'->domain), 'banned_email_domains' => 'Banned Email Domains'->domain))
Arguments: $logs_url, $email
Case if it just banned and the lockout duration too short, we use the locktime instead
Arguments: $model, $scenario
Arguments: apply_filters('wp_defeder/iplockout/email_report_link', network_admin_url('admin.php?page=wdf-ip-lockout&view=logs')), $item['email']
Arguments: network_admin_url('admin.php?page=wdf-ip-lockout&view=logs')
Arguments: network_admin_url('admin.php?page=wdf-ip-lockout&view=reporting'), $item['email']
Arguments: $model, $force, $blacklist
Arguments: $model, $uri, $isBlacklist
Arguments: time()
Priorities - Whitelist extensions files & folders - Blacklist extensions files & folders - attemps inside a window
Arguments: array('192.241.148.185', '104.236.132.222', '192.241.140.159', '192.241.228.89', '198.199.88.192', '54.197.28.242', '54.221.174.186', '54.236.233.244', '127.0.0.1', array_key_exists('SERVER_ADDR', $_SERVER) ? $_SERVER['SERVER_ADDR'] : (isset($_SERVER['LOCAL_ADDR']) ? $_SERVER['LOCAL_ADDR'] : null))
Arguments: '-' . \WP_Defender\Module\IP_Lockout\Model\Settings::instance()->storage_days . ' days'
Make sure those is boolen
Arguments: $content, $viewFile, $params
Total hooks: 73Undocumented hooks: 29
If we are activating a version, while having another present and activated.
<p>Leave in the Pro version, if it is available.</p>
Arguments: WP_SMUSH_BASENAME, 'Smush', '/plugins/wp-smushit/', 'Get Fast!', '4b14b58816'
Allow to add other settings via filtering the variable
<p>Like Nextgen and S3 integration</p>
Arguments: $this->settings
Filter to skip a single image from lazy load.
Arguments: false, $src
$skip - boolShould skip? Default: false.
$skip
$src - stringImage url.
$src
Check if some image formats are excluded.
Arguments: $class
Allows S3 to hook, check and download the file
Arguments: $backup_full_path, $attachment_id, array()
Perform a action after the image URL is updated in post content
Arguments: $image_id, $file_path, $original_file
Filter: wp_smush_image.
<p>Whether to smush the given attachment ID or not.</p>
Arguments: true, $attachment_id
$status - boolSmush all attachments by default.
$status
$attachment_id - intAttachment ID.
$attachment_id
Filter: wp_smush_image
<p>Whether to smush the given attachment id or not</p>
$skip - boolWhether to Smush image or not.
$attachment_id - intAttachment ID of the image being processed.
Arguments: $attachment_file_path, $attachment_id
Resize the dimensions of the image.
<p>Filter whether the existing image should be resized or not</p>
$should_resize - boolSet to True by default.
$should_resize
$attachment_id - intImage Attachment ID.
Arguments: $attachment_id, $stats
Internal filter to disable page parsing.
<p>Because the page parser module is universal, we need to make sure that all modules have the ability to skip parsing of certain pages. For example, lazy loading should skip if_preview() pages. In order to achieve this functionality, I've introduced this filter. Filter priority can be used to overwrite the $skip param.</p>
$skip - boolSkip status.
Filter to skip a single image from cdn.
Arguments: false, $src, $image
$image - array, boolImage tag or false.
$image
array, bool
Filter hook to alter image tag before replacing the image in content.
Arguments: $new_image
$image - stringImage tag.
Filter hook to alter image src arguments before going through cdn.
Arguments: array(), $image
$args - arrayArguments.
$src - stringImage src.
Filter hook to alter image src before going through cdn.
Arguments: $src, $image
Filter hook to alter image src after replacing with CDN base.
Arguments: false, $source['url'], $source
Filter to add/update/bypass additional srcsets.
<p>If empty value or false is retured, additional srcset will not be generated.</p>
Arguments: array(0.2, 0.4, 0.6, 0.8, 1, 2, 3)
$additional_multipliers - array, boolAdditional multipliers.
$additional_multipliers
Arguments: false, $url, false
Arguments: $postid, $_POST
To be stored in DB, Part of code inspired from Ewwww Optimiser
Arguments: $admin_path
Arguments: $skip, $path
Filter whether to convert the PNG to JPG or not
Arguments: $should_convert, $id, $file, $size
$should_convert - boolCurrent choice for image conversion
$should_convert
$id - intAttachment id
$id
$file - stringFile path for the image
$file
$size - stringImage size being converted
$size
Arguments: $id, $file, $n_file, $size
Do action, if the PNG to JPG conversion was successful
Arguments: $id, $meta, $savings
Filter Background Color for Transparent PNGs
Arguments: $transparent_png['background'], $id, $size
Used internally to modify the error message
Arguments: $error, $attachment_id
Allows to format single item in meta.
<p>This filter will be used only for Async, post requests.</p>
Arguments: $value, $key
$value - mixedMeta item value.
$value
mixed
$key - stringMeta item key.
$key
Arguments: 2000
Arguments: 1000
Do not fetch more than this, any time Localizing all rows at once increases the page load and slows down everything
Arguments: 5000
Initialize class variables, after all stuff has been loaded
Arguments: $mime_supported, $mime
Filter whether the uploaded image should be resized or not
Arguments: $should_resize, $id, $meta
$should_resize - bool
$upload - array{ Array of upload data.
$upload
$context - stringThe type of upload action. Values include 'upload' or 'sideload'.
$context
Called after the image has been successfully resized Can be used to update the stored stats
Arguments: $id, $savings
Filter the resize image dimensions
Arguments: array('width' => $this->max_w, 'height' => $this->max_h), $file_path, $id
$sizes - array{ Array of sizes containing max width and height for all the uploaded images.
$sizes
$file_path - stringOriginal Image file path
$file_path
Arguments: file_exists($backup), $image_id, $backup
Allows S3 to hook over here and check if the given file path exists else download the file.
Arguments: $attachment_file_path_size, $id, $size_data
Arguments: true, $size_key
Arguments: true, 'full'
Runs if the image smushing was successful
Arguments: $id, $stats, $meta
$id - intImage Id
$stats - arraySmush Stats for the image
$stats
$meta - arrayAttachment meta.
$meta
Arguments: true, $id
$skip - boolBool, whether to Smush image or not.
$ID - intAttachment Id, Attachment id of the image being processed.
$ID
Fix for Hostgator.
<p>Check for use of http url (Hostgator mostly).</p>
$skip - bool, whether to Smush image or not
$Attachment - Id, Attachment id of the image being processed
$Attachment
$id - intAttachment ID of the image being processed.
AJAX Thumbnail Rebuild integration.
Arguments: $id
Arguments: \WP_Smush::get_instance()->core()->mod->smush->is_auto_smush_enabled()
Arguments: true, $size
Arguments: $image->pid, $stats
$ID - intImage Id
Arguments: $mime_supported, $ext
Filter whether the NextGen image should be resized or not
Arguments: $should_resize, $image, $meta
- objectNextGen Gallery image object
- arrayNextGen Gallery image object
Arguments: $attachment_id, array('stats' => $savings)
Arguments: $attachment_id, $savings
Arguments: $image_id, $stats
Allows to Enable/Disable WP Retina 2x Integration
Arguments: true, $image_size
Do not enqueue, unless it is one of the required screen, or not in WordPress backend.
Arguments: array('bulk' => 'Bulk Smush', 'directory' => 'Directory Smush', 'integrations' => 'Integrations', 'lazy_load' => 'Lazy Load', 'cdn' => 'CDN', 'tools' => 'Tools', 'settings' => 'Settings')
Allows to hook in additional containers after stats box for free version Pro Version has a full width settings box, so we don't want to do it there.
Arguments: $name
Total hooks: 110Undocumented hooks: 86
Allow other plugins to enqueue css/js after shared-ui to overwrite certain definitions.
Display a custom success message on the WPMU Dashboard pages.
Fires when config data has been loaded
<p>Can be used to manipulate the loaded data on the fly.</p>
Arguments: get_home_path()
Arguments: 200
Arguments: DOMAIN_CURRENT_SITE
Arguments: PATH_CURRENT_SITE
Arguments: $filename
Allows to overide Snapshot CRON job run status.
Arguments: $stop
Arguments: $status
Filter Manage file restore
$response - bool
$response
Arguments: $all_tables, $tables
Filter Manage backup table restore
Filter: snapshot_zip_file_corrupt Allows to imitate zip file size getting corrupted after new files are added to it
Arguments: $zip_corrupt
Check for stop.
Automatic backup processing encountered too many errors
Arguments: 'process', $key, $msg
- stringAction type indicator (process or finish)
$key - stringError message key
$msg - stringHuman-friendly message description
$msg
Arguments: 'finish', $key, $msg
Arguments: 5 * 60
Arguments: $next_event + rand(-1 * $disperse, +1 * $disperse)
Arguments: $next_event
Arguments: \Snapshot_Model_Time::get()->get_utc_time() + $this->get_kickstart_delay()
Arguments: $error
Filter Manage backup restore
Arguments: $response
$response - array
- stringAction type indicator (process or finish).
$key - stringError message key.
$msg - stringHuman-friendly message description.
Arguments: $this->is_explicitly_enabled() || $this->is_implicitly_enabled()
Arguments: (bool) $this->_model->get_config('full_log_enable', false)
Arguments: self::LOG_IMPLICIT === $enabled
Successful backup started hook
Arguments: $backup
$this - \Snapshot_Helper_BackupCurrent backup instance.
$this
\Snapshot_Helper_Backup
Arguments: 'process', $error, $backup
$error - stringOffending error message key
$error
$backup - object, boolA Snapshot_Helper_Backup instance, or (bool)false
$backup
object, bool
Successful backup processing hook
Arguments: 'finish', $error, $backup
Successful backup finished hook
Successful backup finishing (uploading) hook
Restore processing hook
Arguments: $restore
$this - \Snapshot_Helper_RestoreCurrent restore instance.
\Snapshot_Helper_Restore
Restore finishing hook
Arguments: $msg, $key
Arguments: $backups
Arguments: (int) wp_remote_retrieve_response_code($result)
Arguments: wp_remote_retrieve_body($result)
Arguments: $help_url, $url
Arguments: $size
Arguments: $total
Arguments: $free
Arguments: $raw
Arguments: self::CACHE_EXPIRATION
Arguments: $this->_get_raw_backup_items()
Arguments: $this->is_dashboard_active() && $this->has_dashboard_key()
Arguments: class_exists('WPMUDEV_Dashboard')
Arguments: $this->get_config('active')
Arguments: $frequencies, $title_case
Arguments: $value
Arguments: $times
Arguments: !empty($backups)
Arguments: array_merge($this->_storage->get_backups(), $this->_local->get_backups())
Arguments: current_time('timestamp', 0)
Arguments: current_time('timestamp', 1)
Arguments: is_multisite() && $include_other, $include_other
Arguments: $this->detect_large_files($files, $chunk), $chunk
Arguments: false, $file, $size, $chunk
Arguments: $threshold
Arguments: $is_wpmu_hosting
Multipart transfer part size, in bytes
Arguments: $increment, $this->get_type(), $this
$increment - intTransfer part size.
$increment
$type - stringTransfer type.
$transfer - objectTransfer implementation object.
$transfer
Arguments: $limit
Total hooks: 89Undocumented hooks: 28
Fires just before the current task processing
Arguments: $task
$task - objectTask instance.
$task
Fires just after the current task processing
Arguments: $task, $status
$status - boolDone or not
Whether to actually include this table in migration processing
Arguments: true, $table
$do_process_item - boolInclude item.
$do_process_item
$table - stringTable name.
$table
Arguments: 250
Number of file statements to upload in one step
Arguments: 10
$limit - intMaximum number of files.
$limit
DEV API service URL
Arguments: $service_url
$service_url - stringShipper DEV API service URL.
$service_url
Pre-process the service call args
Arguments: $args, $endpoint
$args - arrayRemote request arguments.
$endpoint - stringRequested endpoint.
$endpoint
Whether we're in import mocking mode, defaults to false.
<p>In files import mocking mode, none of the files will be actually copied over to their final destination.</p>
$is_mock_import - boolWhether we're in mock import mode.
$is_mock_import
Source tables processing list
<p>Used in tests suite.</p>
Arguments: $tables
$tables - arrayList of extracted table names (from SQL files).
$tables
Arguments: 25
<p>In tables import mocking mode, intermediate tables will be created. However, they won't be ported over to the existing tables. As a side-effect of this, the database size <em>will</em> double.</p>
Arguments: \Shipper_Model_Env::is_auth_requiring_env()
Whether the file is deployable
Arguments: true, basename($filepath), $filepath
$deployable - boolWhether the file is deployable.
$deployable
$basename - stringBasename of the file.
$basename
$path - stringFull path to the file.
$path
Dashboard present check filter
Arguments: $present
$result - Whether the dash is present.
Dashboard active check filter
$result - Whether the dash is active.
Dashboard API key presence check filter
Arguments: $model->get('api_key')
$result - Whether the dash API key is present.
Arguments: 600, $this->_process
Fires on kickstart attempt
Fires just before runner tick processing, after locking
$runner - objectRunner instance.
$runner
Fires on stale lock removal
Arguments: $lock
$lock - stringProcess lock identifier.
$lock
Gets the runner ping timeout
<p>This is a (fractional) number of seconds we're allowing to our self-ping POST request to run.</p> <p>Default is 30s for blocking requests, and 0.5s for non-blocking.</p>
Arguments: $timeout
$timeout - floatPing timeout, in seconds.
$timeout
float
Whether the runner self-ping request is a blocking one
<p>Defaults to false.</p>
$is_blocking - boolWhether the request will be a blocking one.
$is_blocking
Triggers just before cron respawning.
<p>Used in tests</p>
Whether to update the DEV API on migration progress status
Arguments: true, $task
$do_update - boolWhether to send status update.
$do_update
$task - objectOverall task (which can be queried for has_completed_task).
has_completed_task
Fires on remote migration kickstart
Whether to clear the log on migration prep
Arguments: true, $migration
$clear_log - boolWhether to clear the log or not.
$clear_log
$migration - objectShipper_Model_Stored_Migration instance.
$migration
Fires on migration start
Arguments: $migration
Fires on migration complete.
- objectShipper_Model_Stored_Migration instance.
Fires on migration cancel, just before sending out any remote cancel requests
Fires on migration cancel
Fires on each completed tick
Arguments: $migration, $task, $status
$migration - objectMigration model instance.
$task - objectOverall task instance.
$status - boolMigration completion status.
Debug mode filter
<p>Debug mode affects FS storage implementation and cancels out the concealments/obfuscation for easier debugging.</p>
$is_in_debug_mode - bool Defaults to false.
$is_in_debug_mode
Arguments: 200, $this
Max number of paths to be processed per step
<p>Number of files processed is directly dependent on this.</p>
Arguments: $limit, $this->is_excludable()
$paths_count - intNumber of paths to process.
$paths_count
$is_excludable - boolWhether we're excluding files (false means preflight).
$is_excludable
Max number of bytes to process per step
$bytes - intNumber of bytes to process.
$bytes
Whether to actually include this item in list processing
Arguments: true, $item
$item - stringItem path.
Gets the working directory root path
<p>Defaults to system temp directory, or best guesstimate.</p>
Arguments: get_temp_dir()
$root_path - stringTemporary working directory.
$root_path
Gets the actual working directory path
Arguments: $shipper_dir
$shipper_dir - stringShipper working directory path.
$shipper_dir
Stale locks cleanup check
<p>This is how we decide whether to clear stale locks. We are doing this because clearing "stale" locks messes up the import process if set_time_limit <em>actually</em> does what it's supposed to do, which might not always be the case :(</p>
$forbid_cleanup - boolIf true, stale locks will not be cleared.
$forbid_cleanup
Gets the site-specific obfuscation key
Arguments: $key, $fallback
$key - stringSite-specific obfuscation key.
$fallback - stringOptional provided fallback.
$fallback
Allows for domain-with-scheme macro opting out
$include_scheme_macro - boolWhether to include the scheme macro.
$include_scheme_macro
Arguments: $this->get_replacements_list()
Arguments: $this->get_original_value($original)
Gets the update interval for Heartbeat API
Arguments: 15
$update_interval - int, stringHeartbeat update interval.
$update_interval
int, string
Returns FS path to shipper icon.
Arguments: plugin_dir_path(SHIPPER_PLUGIN_FILE) . 'assets/img/anchor.svg'
$icon_path - stringPath to icon.
$icon_path
Arguments: $default
Arguments: 5
Max exec time before limit optimization
Arguments: self::$_max_exec_time
$time - intMaximum execution time.
$time
Maximum execution time
Arguments: 180
Whether a function call is disabled.
Arguments: !$callable, $func
$disabled - boolWhether a function call is disabled.
$disabled
$func - stringFunction to check.
$func
Whether an ini key is changeable.
Arguments: wp_is_ini_value_changeable($what), $what
$changeable - boolWhether the key is changeable.
$changeable
$what - stringIni key to check.
$what
Checks whether we're in PHP safe mode.
Arguments: !empty($is_safe_mode) && 'off' !== $is_safe_mode
$is_in_safe_mode - boolWhether we're in safe mode.
$is_in_safe_mode
Resolved table names, according to unpacked files
$tables - arrayResolved table names.
The row values to be updated in the destination table.
Arguments: $dest_row, $row, $table
$dest_row - arrayProcessed row values.
$dest_row
$row - arraySource (unprocessed) row.
$row
$table - stringTable that the row belongs to.
Arguments: $this->get_destination_table()
Arguments: false, $table
Row size limit, in bytes
Arguments: $limit, $table
$limit - intSize, in bytes.
Whether to include transients in migration
Arguments: true, $raw, $table
$include - boolWhether to include transients in export.
$include
$raw - arrayRaw row hash.
$raw
Whether to include this row in migration
Arguments: $include, $raw, $table
$include - boolWhether to include the row in export.
Decide whether we're in an auth-requiring environment.
<p>Used in building ping request arguments to establish runner execution context.</p>
Arguments: \Shipper_Model_Env::is_wp_engine()
$is_auth - boolCheck result this far.
$is_auth
Whether or not we're dealing with Flywheel environment
Arguments: defined('FLYWHEEL_PLUGIN_DIR')
$is_flywheel - boolFlywheel environment detected.
$is_flywheel
Maximum individual file size allowed before issuing a warning
Arguments: $max
$max - intMaximum file size, in bytes.
$max
Maximum raw package size allowed before issuing a warning
$max - intMaximum package size, in bytes.
Arguments: self::THRESHOLD_KICKSTARTS
Cancel await max time
<p>Default 30 secs, in microseconds.</p>
Arguments: (int) ((double) $secs * $micro)
$time - intTime to spend awaiting cancel lock, in microseconds.
Cancel await step
<p>Default 1 sec, in microseconds.</p>
Arguments: (int) ((double) $step * $micro)
$time - intTime to spend hibernating between cancel lock checks, in microseconds.
Gets domain-based unique site identifier
Arguments: preg_replace('/-+/', '-', $id), $prefix
$uniqid - stringSafe-ranged identifier.
$uniqid
$prefix - stringOptional prefix.
$prefix
List of users allowed to access WPMU DEV Dashboard
Arguments: $dash_users
$dash_users - arrayA list of users allowed to access WPMU DEV Dashboard.
$dash_users
Total hooks: 166Undocumented hooks: 47
filter by WP version
Arguments: $modules
Section for network only
Arguments: false, $module, null
add reset
table foot content filter
Arguments: $table_footer, $module, $section_key
$table_footer - stringCurrent footer.
$table_footer
$module - stringCurrent module.
$module
$section_key - stringCurrent section.
$section_key
add reset whole module button
Arguments: true, $module
Filter content
Arguments: '', $module
actions with "do"
Arguments: $success, $module, $section
version
Arguments: false, $module
Filter allow to change module availability.
- boolean
$module - arrayModule data.
debug only when WP_DEBUG && WPMUDEV_BETATEST
Arguments: $debug
Filter allow to turn off available modules.
Arguments: $this->modules
$modules - arrayavailable modules array.
$modules
Filter allow to avoid run wp_enqueue* functions.
$add - booleanLoad assets or not load - it is a question.
$add
Filter messages array
set related
Arguments: $this->related
Add groups submenus
Arguments: false, $key, $modules
Check show?
Arguments: $module
check
check for subsites
Arguments: false, $key, $module
render
Arguments: array(), $this->module
Messages
Arguments: $this->hide_branding
Arguments: null
Arguments: array('url' => $this->get_network_permissions_url(), 'show' => true)
Arguments: $classes, $this->module
Arguments: '', $this->module
Hide options if subsites configuration
Arguments: false, $id, $module
submit button
body
Arguments: $classes, $module
Modules Status & Manage All Modules
Arguments: $hide_footer, $this->module
Arguments: $footer_text, $this->module
Arguments: $this->module
Set default "Can Dissmiss" only when it is not set, and set it to false for "success" $class and false otherwise set true
Arguments: false, $module, $this->configuration[$module]
Filter
Form encoding type
Arguments: 'multipart/form-data'
Fields with form
Arguments: $this->messages
Filter Branda form classes.
Arguments: array('branda-form', sprintf('module-%s', sanitize_title($module['key'])), $this->is_network ? 'branda-network' : 'branda-single'), $module
$classes - array Array of Branda form classes.
$module - array Current module data,
Arguments: 'post'
nonce
footer
Arguments: $args, $module
filter module content.
Arguments: $content, $module
$content - stringCurrent module content.
$content
$module - arrayCurrent module.
get module
Set hide branding
Background
get content
Allow to change fields.
Arguments: $data, $defaults, $this->module
$data - arrayOptions data.
$data
$defaults - arrayDefault values from function.
$defaults
- stringCurrent module name.
Content
Arguments: get_bloginfo('name')
Arguments: get_bloginfo('admin_email')
Allow to change content logo fields.
$data - arraylogo options data.
$this->module - stringCurrent module name.
$this->module
Colors: General: Background
Arguments: $content, $this->get_value()
Allow to change logo css args
Arguments: $args
Allow to change logo css
Arguments: $this->render($template, $args, true), $args
Hide it all
Arguments: $post->post_title
Allows to enable or disable Next Line to br tag conversion
Filter the post list displayed in email sidebar
Arguments: $posts_list
$posts_list - array, An array of posts, containing ID and post_title for each post
$posts_list
Filter the sidebar title in email template
Arguments: $title = 'What\'s new'
$title - string, Title to be displayed in email
$title
Arguments: $v
Dialog
Arguments: $widget_id
Arguments: empty($instance['title']) ? 'Meta' : $instance['title'], $instance, $this->id_base
Dialog settings
Arguments: $_POST['content']
export
If it is a subsite export, then we should limit exported data.
Data to export
Handle import errors
KM_Download_Remote_Image
update import stats
Arguments: 'import'
Options
Arguments: false, $this->module, null
save
How much modules show on "Frequently Used" block.
- integerNumber of modules to show
integer
Arguments: false, $option
For mode 'raw' do nor use filters.
Arguments: $value, $option, $default
Arguments: $option
Filter allow to turn on/off modules.
Arguments: $branda_modules
$modules - arrayActive modules array.
Arguments: 'unknown', $module
handle ajax
avoid to compare with development version for deprecated check
check modules to off
Arguments: $this->configuration
Arguments: '2 weeks ago'
Arguments: $terms
Arguments: $log_id
set debug when WP_DEBUG or WPMUDEV_BETATEST
Add defaults
Arguments: $data, $this->module, $section, $name
Arguments: $this->option_name
Add settings sections to prevent delete on save.
<p>Add settings sections (virtual options not included in "set_options()" function to avoid delete during update.</p>
do action
Arguments: $this->module, $value, $current_value
Allow to change background options.
$data - arrayBackground options data.
Allow to change content fields.
Allow to change Social Media Settings options.
Allow to change attributes
Arguments: $attr, $this->module, $id
Automagically enqueue module admin js.
Arguments: array(), $module
Run action to enqueue modules relted screipts.
get algorithm
Arguments: 'crc32'