wpseek.com
Un motore di ricerca WordPress per sviluppatori e autori di temi
wp-includes/formatting.php › WordPress File
Funzioni118
› Main WordPress Formatting API.
Function | Short description |
---|---|
addslashes_gpc | Adds slashes to a string or recursively adds slashes to strings within an array. |
antispambot | Converts email addresses characters to HTML entities to block spam bots. |
backslashit | Adds backslashes before letters and before a number at the start of a string. |
balancetags | Balances tags if forced to, or if the 'use_balanceTags' option is set to true. |
capital_p_dangit | Forever eliminate "Wordpress" from the planet (or at least the little bit we can influence). |
convert_chars | Converts lone & characters into `&` (a.k.a. `&`) |
convert_invalid_entities | Converts invalid Unicode references range to valid range. |
convert_smilies | Converts text equivalent of smilies to images. |
ent2ncr | Converts named entities into numbered entities. |
esc_attr | Escaping for HTML attributes. |
esc_html | Escaping for HTML blocks. |
esc_js | Escapes single quotes, `"`, `<`, `>`, `&`, and fixes line endings. |
esc_sql | Escapes data for use in a MySQL query. |
esc_textarea | Escaping for textarea values. |
esc_url | Checks and cleans a URL. |
esc_url_raw | Sanitizes a URL for database or redirect usage. |
esc_xml | Escaping for XML blocks. |
force_balance_tags | Balances tags of string using a modified stack. |
format_for_editor | Formats text for the editor. |
format_to_edit | Acts on text which is about to be edited. |
get_date_from_gmt | Given a date in UTC or GMT timezone, returns that date in the timezone of the site. |
get_gmt_from_date | Given a date in the timezone of the site, returns that date in UTC. |
get_html_split_regex | Retrieves the regular expression for an HTML element. |
get_url_in_content | Extracts and returns the first URL from passed content. |
htmlentities2 | Converts entities, while preserving already-encoded entities. |
human_time_diff | Determines the difference between two timestamps. |
iso8601_timezone_to_offset | Given an ISO 8601 timezone, returns its UTC offset in seconds. |
iso8601_to_datetime | Given an ISO 8601 (Ymd\TH:i:sO) date, returns a MySQL DateTime (Y-m-d H:i:s) format used by post_date[_gmt]. |
is_email | Verifies that an email is valid. |
links_add_base_url | Adds a base URL to relative links in passed content. |
links_add_target | Adds a target attribute to all links in passed content. |
make_clickable | Converts plaintext URI to HTML links. |
map_deep | Maps a function to all non-iterable elements of an array or an object. |
maybe_hash_hex_color | Ensures that any hex color is properly hashed. |
normalize_whitespace | Normalizes EOL characters and strips duplicate whitespace. |
print_emoji_detection_script | Prints the inline Emoji detection script if it is not already printed. |
rawurlencode_deep | Navigates through an array, object, or scalar, and raw-encodes the values to be used in a URL. |
remove_accents | Converts all accent characters to ASCII characters. |
sanitize_email | Strips out all characters that are not allowable in an email. |
sanitize_file_name | Sanitizes a filename, replacing whitespace with dashes. |
sanitize_hex_color | Sanitizes a hex color. |
sanitize_hex_color_no_hash | Sanitizes a hex color without a hash. Use sanitize_hex_color() when possible. |
sanitize_html_class | Sanitizes an HTML classname to ensure it only contains valid characters. |
sanitize_key | Sanitizes a string key. |
sanitize_locale_name | Strips out all characters not allowed in a locale name. |
sanitize_mime_type | Sanitizes a mime type |
sanitize_option | Sanitizes various option values based on the nature of the option. |
sanitize_sql_orderby | Ensures a string is a valid SQL 'order by' clause. |
sanitize_textarea_field | Sanitizes a multiline string from user input or from the database. |
sanitize_text_field | Sanitizes a string from user input or from the database. |
sanitize_title | Sanitizes a string into a slug, which can be used in URLs or HTML attributes. |
sanitize_title_for_query | Sanitizes a title with the 'query' context. |
sanitize_title_with_dashes | Sanitizes a title, replacing whitespace and a few other characters with dashes. |
sanitize_trackback_urls | Sanitizes space or carriage return separated URLs that are used to send trackbacks. |
sanitize_url | Sanitizes a URL for database or redirect usage. |
sanitize_user | Sanitizes a username, stripping out unsafe characters. |
seems_utf8 | Checks to see if a string is utf8 encoded. |
shortcode_unautop | Don't auto-p wrap shortcodes that stand alone. |
stripslashes_deep | Navigates through an array, object, or scalar, and removes slashes from the values. |
stripslashes_from_strings_only | Callback function for `stripslashes_deep()` which strips slashes from strings. |
tag_escape | Escapes an HTML tag name. |
trailingslashit | Appends a trailing slash. |
translate_smiley | Converts one smiley code to the icon graphic file equivalent. |
untrailingslashit | Removes trailing forward slashes and backslashes if they exist. |
urldecode_deep | Navigates through an array, object, or scalar, and decodes URL-encoded values |
urlencode_deep | Navigates through an array, object, or scalar, and encodes the values to be used in a URL. |
url_shorten | Shortens a URL, to be used as link text. |
utf8_uri_encode | Encodes the Unicode values to be used in the URI. |
wpautop | Replaces double line breaks with paragraph elements. |
wptexturize | Replaces common plain text characters with formatted entities. |
wptexturize_primes | Implements a logic tree to determine whether or not "7'." represents seven feet, then converts the special char into either a prime char or a closing quote char. |
wp_basename | i18n-friendly version of basename(). |
wp_check_invalid_utf8 | Checks for invalid UTF8 in a string. |
wp_encode_emoji | Converts emoji characters to their equivalent HTML entity. |
wp_enqueue_emoji_styles | Enqueues the important emoji-related styles. |
wp_html_excerpt | Safely extracts not more than the first $count characters from HTML string. |
wp_html_split | Separates HTML elements and comments from the text. |
wp_init_targeted_link_rel_filters | Adds all filters modifying the rel attribute of targeted links. |
wp_iso_descrambler | Converts to ASCII from email subjects. |
wp_make_link_relative | Converts full URL paths to absolute paths. |
wp_parse_str | Parses a string into variables to be stored in an array. |
wp_pre_kses_block_attributes | Removes non-allowable HTML from parsed block attribute values when filtering in the post context. |
wp_pre_kses_less_than | Converts lone less than signs. |
wp_pre_kses_less_than_callback | Callback function used by preg_replace. |
wp_rel_callback | Callback to add a rel attribute to HTML A element. |
wp_rel_nofollow | Adds `rel="nofollow"` string to all HTML A elements in content. |
wp_rel_nofollow_callback | Callback to add `rel="nofollow"` string to HTML A element. |
wp_rel_ugc | Adds `rel="nofollow ugc"` string to all HTML A elements in content. |
wp_remove_targeted_link_rel_filters | Removes all filters modifying the rel attribute of targeted links. |
wp_replace_in_html_tags | Replaces characters or phrases within HTML elements only. |
wp_slash | Adds slashes to a string or recursively adds slashes to strings within an array. |
wp_spaces_regexp | Returns the regexp for common whitespace characters. |
wp_specialchars_decode | Converts a number of HTML entities into their special characters. |
wp_sprintf | WordPress' implementation of PHP sprintf() with filters. |
wp_sprintf_l | Localizes list items before the rest of the content. |
wp_staticize_emoji | Converts emoji to a static img element. |
wp_staticize_emoji_for_email | Converts emoji in emails into static images. |
wp_strip_all_tags | Properly strips all HTML tags including 'script' and 'style'. |
wp_targeted_link_rel | Adds `rel="noopener"` to all HTML A elements that have a target. |
wp_targeted_link_rel_callback | Callback to add `rel="noopener"` string to HTML A element. |
wp_trim_excerpt | Generates an excerpt from the content, if needed. |
wp_trim_words | Trims text to a certain number of words. |
wp_unslash | Removes slashes from a string or recursively removes slashes from strings within an array. |
zeroise | Add leading zeros when necessary. |
_autop_newline_preservation_helper | Newline preservation help function for wpautop(). |
_deep_replace | Performs a deep string replace operation to ensure the values in $search are no longer present. |
_links_add_base | Callback to add a base URL to relative links in passed content. |
_links_add_target | Callback to add a target attribute to all links in passed content. |
_make_clickable_rel_attr | Helper function used to build the "rel" attribute for a URL when creating an anchor using make_clickable(). |
_make_email_clickable_cb | Callback to convert email address match to HTML A element. |
_make_url_clickable_cb | Callback to convert URI match to HTML A element. |
_make_web_ftp_clickable_cb | Callback to convert URL match to HTML A element. |
_sanitize_text_fields | Internal helper function to sanitize a string from user input or from the database. |
_split_str_by_whitespace | Breaks a string into chunks by splitting at whitespace characters. |
_wptexturize_pushpop_element | Searches for disabled element tags. Pushes element to stack on tag open and pops on tag close. |
_wp_emoji_list | Returns arrays of emoji data. |
_wp_iso_convert | Helper function to convert hex encoded chars to ASCII. |
_wp_specialchars | Converts a number of special characters into their HTML entities. |