Functions
Parsing the WordPress 7.1.0 source turned up 4,809 functions. A function here is any callable declared in WordPress core, from template tags like the_title() to internal helpers prefixed with an underscore. Each page below is generated from the function's own declaration and documentation block, and records the parameters it takes, what it returns, the hooks it fires while it runs, and every place in core that calls it.
4,809 functions · page 1 of 49
- _()Compat function to mimic _(), an alias of gettext().
- __()Retrieves the translation of $text.
- __checked_selected_helper()Private helper function for checked, selected, disabled and readonly.
- __clear_multi_author_cache()Helper function to clear the cache for number of authors.
- __get_option()Utility version of get_option that is private to installation/upgrade.
- __ngettext()deprecatedRetrieve the plural or single form based on the amount.
- __ngettext_noop()deprecatedRegister plural strings in POT file, but don't translate them.
- __return_empty_array()Returns an empty array.
- __return_empty_string()Returns an empty string.
- __return_false()Returns false.
- __return_null()Returns null.
- __return_true()Returns true.
- __return_zero()Returns 0.
- _access_denied_splash()Displays an access denied message when a user tries to view a site's dashboard they do not have access to.
- _add_block_template_info()Attempts to add custom template information to the template item.
- _add_block_template_part_area_info()Attempts to add the template part's area information to the input template.
- _add_default_theme_supports()Adds default theme supports for block themes when the 'after_setup_theme' action fires.
- _add_plugin_file_editor_to_tools()Adds the 'Plugin File Editor' menu item after the 'Themes File Editor' in Tools for block themes.
- _add_post_type_submenus()Adds submenus for post types.
- _add_template_loader_filters()Adds necessary hooks to resolve '_wp-find-template' requests.
- _add_themes_utility_last()Adds the 'Theme File Editor' menu item to the bottom of the Appearance (non-block themes) or Tools (block themes) menu.
- _admin_bar_bump_cb()deprecatedPrints default admin bar callback.
- _admin_notice_post_locked()Outputs the HTML for the notice to say that someone else is editing or has taken over editing of this post.
- _admin_search_query()Displays the search query.
- _ajax_wp_die_handler()Kills WordPress execution and displays Ajax response with an error message.
- _autop_newline_preservation_helper()Newline preservation help function for wpautop().
- _block_bindings_pattern_overrides_get_value()Gets value for the Pattern Overrides source.
- _block_bindings_post_data_get_value()Gets value for Post Data source.
- _block_bindings_post_meta_get_value()Gets value for Post Meta source.
- _block_bindings_term_data_get_value()Gets value for Term Data source.
- _block_template_add_skip_link()Inserts the block template skip-link into the template HTML.
- _block_template_render_title_tag()Displays title tag with content, regardless of whether theme has title-tag support.
- _block_template_render_without_post_block_context()Removes post details from block context when rendering a block template.
- _block_template_viewport_meta_tag()Renders a 'viewport' meta tag.
- _build_block_template_object_from_post_object()Builds a block template object from a post object.
- _build_block_template_result_from_file()Builds a unified template object based on a theme file.
- _build_block_template_result_from_post()Builds a unified template object based a post Object.
- _c()deprecatedRetrieve translated string with vertical bar context
- _canonical_charset()Retrieves a canonical form of the provided charset appropriate for passing to PHP functions such as htmlspecialchars() and charset HTML attributes.
- _cleanup_header_comment()Strips close comment and close php tags from file headers used by WP.
- _cleanup_image_add_caption()Private preg_replace callback used in image_add_caption().
- _clear_modified_cache_on_transition_comment_status()Clears the lastcommentmodified cached value when a comment status is changed.
- _close_comments_for_old_post()Closes comments on an old post. Hooked to comments_open and pings_open.
- _close_comments_for_old_posts()Closes comments on old posts on the fly, without any extra DB queries. Hooked to the_posts.
- _config_wp_home()Retrieves the WordPress home page URL.
- _config_wp_siteurl()Retrieves the WordPress site URL.
- _copy_image_file()Copies an existing image file.
- _count_posts_cache_key()Returns the cache key for wp_count_posts() based on the passed arguments.
- _crop_image_resource()Crops an image resource. Internal use only.
- _custom_background_cb()Default custom background callback.
- _custom_header_background_just_in_time()Registers the internal custom header and background routines.
- _custom_logo_header_styles()Adds CSS to hide header text for custom logo, based on Customizer setting.
- _customizer_mobile_viewport_meta()Adds viewport meta for mobile in Customizer.
- _deep_replace()Performs a deep string replace operation to ensure the values in $search are no longer present.
- _default_wp_die_handler()Kills WordPress execution and displays HTML page with an error message.
- _delete_attachment_theme_mod()Checks an attachment being deleted to see if it's a header or background image.
- _delete_custom_logo_on_remove_site_logo()Removes the custom_logo theme-mod when the site_logo option gets deleted.
- _delete_option_fresh_site()Deletes the fresh site option.
- _delete_site_logo_on_remove_custom_logo()Deletes the site_logo when the custom_logo theme mod is removed.
- _delete_site_logo_on_remove_custom_logo_on_setup_theme()Hooks `_delete_site_logo_on_remove_custom_logo` in `update_option_theme_mods_$theme`.
- _delete_site_logo_on_remove_theme_mods()Deletes the site logo when all theme mods are being removed.
- _deprecated_argument()Marks a function argument as deprecated and inform when it has been used.
- _deprecated_class()Marks a class as deprecated and informs when it has been used.
- _deprecated_constructor()Marks a constructor as deprecated and informs when it has been used.
- _deprecated_file()Marks a file as deprecated and inform when it has been used.
- _deprecated_function()Marks a function as deprecated and inform when it has been used.
- _deprecated_hook()Marks a deprecated action or filter hook as deprecated and throws a notice.
- _device_can_upload()Tests if the current device has the capability to upload files.
- _disable_block_editor_for_navigation_post_type()Disables block editor for wp_navigation type posts so they can be managed via the UI.
- _disable_content_editor_for_navigation_post_type()This callback disables the content editor for wp_navigation type posts.
- _doing_it_wrong()Marks something as being incorrectly called.
- _draft_or_post_title()Gets the post title.
- _e()Displays translated text.
- _enable_content_editor_for_navigation_post_type()This callback enables content editor for wp_navigation type posts.
- _ex()Displays translated string with gettext context.
- _excerpt_render_inner_blocks()Renders inner blocks from the allowed wrapper blocks for generating an excerpt.
- _excerpt_render_inner_columns_blocks()deprecatedRender inner blocks from the `core/columns` block for generating an excerpt.
- _fetch_remote_file()Retrieve URL headers and content using WP HTTP Request API.
- _filter_block_content_callback()Callback used for regular expression replacement in filter_block_content().
- _filter_block_template_part_area()Checks whether the input 'area' is a supported value.
- _filter_do_shortcode_context()Filter the `wp_get_attachment_image_context` hook during shortcode rendering.
- _filter_query_attachment_filenames()deprecatedFilter the SQL clauses of an attachment query to include filenames.
- _find_post_by_old_date()Find the post ID for redirecting an old date.
- _find_post_by_old_slug()Find the post ID for redirecting an old slug.
- _fix_attachment_links()Replaces hrefs of attachment anchors with up-to-date permalinks.
- _flatten_blocks()Returns an array containing the references of the passed blocks and their inner blocks.
- _flip_image_resource()deprecatedFlips an image resource. Internal use only.
- _future_post_hook()Hook used to schedule publication for a post marked for the future.
- _get_additional_user_keys()Returns a list of meta keys to be (maybe) populated in wp_update_user().
- _get_admin_bar_pref()Retrieves the admin bar display preference of a user.
- _get_block_template_file()Retrieves the template file from the theme for a given slug.
- _get_block_templates_files()Retrieves the template files from the theme.
- _get_block_templates_paths()Finds all nested template part file paths in a theme's directory.
- _get_comment_reply_id()Gets the comment's reply to ID from the $_GET['replytocom'].
- _get_component_from_parsed_url_array()Retrieves a specific component from a parsed URL array.
- _get_cron_array()Retrieves cron info array option.
- _get_cron_lock()Retrieves the cron lock.
- _get_custom_object_labels()Builds an object with custom-something object (post type, taxonomy) labels out of a custom-something object
- _get_dropins()Returns drop-in plugins that WordPress uses.
- _get_last_post_time()Gets the timestamp of the last time any post was modified or published.