WordPress Snippet

ワードプレスをカスタマイズしよう

WordPress 3.4で追加された関数

WordPress 3.4 new functions

Function Short description Path
display_header_text Whether to display the header text. wp-includes/theme.php
get_allowed_http_origins Retrieve list of allowed http origins. wp-includes/http.php
get_all_post_type_supports Get all the post type features wp-includes/post.php
get_custom_header Get the header image data. wp-includes/theme.php
get_http_origin Get the HTTP Origin of the current request. wp-includes/http.php
get_page_template_slug Get the specific template name for a page. wp-includes/post-template.php
is_allowed_http_origin Determines if the http origin is an authorized one. wp-includes/http.php
maybe_hash_hex_color Ensures that any hex color is properly hashed. wp-includes/class-wp-customize-manager.php
rawurlencode_deep Navigates through an array and raw encodes the values to be used in a URL. wp-includes/formatting.php
sanitize_hex_color Validates a hex color. wp-includes/class-wp-customize-manager.php
sanitize_hex_color_no_hash Sanitizes a hex color without a hash. Use sanitize_hex_color() when possible. wp-includes/class-wp-customize-manager.php
sanitize_trackback_urls Sanitize space or carriage return separated URLs that are used to send trackbacks. wp-includes/formatting.php
send_origin_headers Send Access-Control-Allow-Origin and related headers if the current request

is from an allowed origin.

wp-includes/http.php
set_url_scheme Set the scheme for a URL wp-includes/link-template.php
term_is_ancestor_of Check if a term is an ancestor of another term. wp-includes/taxonomy.php
upgrade_340 Execute changes made in WordPress 3.4. wp-admin/includes/upgrade.php
wp_customize_support_script Prints a script to check whether or not the customizer is supported,

and apply either the no-customize-support or customize-support class
to the body.

wp-includes/theme.php
wp_customize_url Returns a URL to load the theme customizer. wp-includes/theme.php
wp_delete_auto_drafts Deletes auto-drafts for new posts that are > 7 days old wp-includes/post.php
wp_get_theme Gets a WP_Theme object for a theme. wp-includes/theme.php
wp_get_themes Returns an array of WP_Theme objects based on the arguments. wp-includes/theme.php
wp_load_translations_early Attempts an early load of translations. wp-includes/load.php
wp_plupload_default_settings Prints default plupload arguments. wp-includes/media.php
wp_set_comment_cookies Sets the cookies used to store an unauthenticated commentator’s identity. Typically used

to recall previous comments by this commentator that are still held in moderation.

wp-includes/comment.php
_ajax_wp_die_handler Kill WordPress ajax execution. wp-includes/functions.php
_cleanup_image_add_caption Private preg_replace callback used in image_add_caption() wp-admin/includes/media.php
_copy_image_file Copy an existing image file. wp-admin/includes/image.php
_custom_header_background_just_in_time Registers the internal custom header and background routines. wp-includes/theme.php
_device_can_upload Test if the current device has the capability to upload files. wp-includes/functions.php
_get_non_cached_ids Retrieve ids that are not already present in the cache wp-includes/functions.php
_get_random_header_data Get random header image data from registered images in theme. wp-includes/theme.php
_load_image_to_edit_path Retrieve the path or url of an attachment’s attached file. wp-admin/includes/image.php
_prime_post_caches Adds any posts from the given ids to the cache that do not already exist in cache wp-includes/post.php
_scalar_wp_die_handler Kill WordPress execution. wp-includes/functions.php
_split_str_by_whitespace Breaks a string into chunks by splitting at whitespace characters. wp-includes/formatting.php
_update_blog_date_on_post_delete Handler for updating the blog date when a published post is deleted. wp-includes/ms-blogs.php
_wp_customize_include Includes and instantiates the WP_Customize_Manager class. wp-includes/theme.php
_wp_customize_loader_settings Adds settings for the customize-loader script. wp-includes/theme.php
__return_null Returns null. wp-includes/functions.php

@source:Functions added in latest WordPress – WPSeek.com – A WordPress-centric search engine for devs and theme authors.