Home  >  Article  >  Backend Development  >  Complete list of PHP string processing functions

Complete list of PHP string processing functions

WBOY
WBOYOriginal
2016-07-25 09:12:39790browse
  • addcslashes — Escape characters in a string using backslashes, C-style
  • addslashes — Use backslashes to quote strings
  • bin2hex — Convert binary data to hexadecimal representation
  • chop — alias for rtrim
  • chr — Returns the specified character
  • chunk_split — Split a string into small chunks
  • convert_cyr_string — Convert characters from one Cyrillic character to another
  • convert_uudecode — Decode a uuencoded string
  • convert_uuencode — Encode a string using uuencode
  • count_chars — Returns information about the characters used in a string
  • crc32 — Compute the crc32 polynomial of a string
  • crypt — One-way string hashing
  • echo — Output one or more strings
  • explode — Split one string into another
  • fprintf — writes a formatted string to a stream
  • get_html_translation_table — Returns the translation table using htmlspecialchars and htmlentities
  • hebrev — Convert logical-Hebrew to visual-Hebrew
  • hebrevc — Convert logical-Hebrew to visual-Hebrew and convert newlines
  • hex2bin — Convert hexadecimal string to binary string
  • html_entity_decode — Convert all HTML entities to their applicable characters
  • htmlentities — Convert all applicable characters to HTML entities
  • htmlspecialchars_decode — Convert special HTML entities back to normal characters
  • htmlspecialchars — Convert special characters to HTML entities
  • implode — Convert the values ​​of a one-dimensional array into a string
  • join — alias implode
  • lcfirst — Make the first character of a string lowercase
  • levenshtein — Calculate the edit distance between two strings
  • localeconv — Get numeric formatting information
  • ltrim — Remove whitespace characters (or other characters) at the beginning of a string
  • md5_file — Calculate the MD5 hash value of the specified file
  • md5 — Computes the MD5 hash of a string
  • metaphone — Calculate the metaphone key of a string
  • money_format — Formats a number as a currency string
  • nl_langinfo — Query language and locale information
  • nl2br — Insert HTML newlines before all new lines in a string
  • number_format — Format a number with thousands separators
  • ord — Returns the ASCII code value of a character
  • parse_str — Parse a string into multiple variables
  • print — output string
  • printf — output formatted string
  • quoted_printable_decode — Convert a quoted-printable string to an 8 bit string
  • quoted_printable_encode — Convert a 8 bit string to a quoted-printable string
  • quotemeta — Quote meta characters
  • rtrim — remove whitespace characters (or other characters) from the end of a string
  • setlocale — Set locale information
  • sha1_file — Calculate the sha1 hash of a file
  • sha1 — Computes the sha1 hash value of a string
  • similar_text — Calculate the similarity of two strings
  • soundex — Calculate the soundex key of a string
  • sprintf — Return a formatted string
  • sscanf — Parse input characters according to the specified format
  • str_getcsv — Parse a CSV string into an array
  • str_ireplace — Case-ignoring version of str_replace
  • str_pad — Pad a string to a specified length with another string
  • str_repeat — Repeat a string
  • str_replace — Substring replacement
  • str_rot13 — Perform ROT13 conversion on a string
  • str_shuffle — Randomly shuffle a string
  • str_split — Convert string to array
  • str_word_count — Returns the usage of words in a string
  • strcasecmp — Binary safe comparison of strings (case insensitive)
  • strchr — alias strstr
  • strcmp — Binary safe string comparison
  • strcoll — Locale-based string comparison
  • strcspn — Get the length of the starting substring of the non-matching mask
  • strip_tags — Strip HTML and PHP tags from strings
  • stripcslashes — dequote a string escaped using addcslashes
  • stripos — Find the first occurrence of a string (case insensitive)
  • stripslashes — dequote a quoted string
  • stristr — A case-ignoring version of the strstr function
  • strlen — Get the length of a string
  • strnatcasecmp — Compare strings using the "natural order" algorithm (case-insensitive)
  • strnatcmp — Compare strings using natural ordering algorithm
  • strncasecmp — Binary safe comparison of several characters at the beginning of a string (case insensitive)
  • strncmp — Binary safe comparison of several characters at the beginning of a string
  • strpbrk — Find any character in a set of characters in a string
  • strpos — Find the first occurrence of a string
  • strrchr — Find the last occurrence of a specified character in a string
  • strrev — Reverse a string
  • strripos — Calculate the position of the last occurrence of the specified string in the target string (case-insensitive)
  • strrpos — Calculate the position of the last occurrence of the specified string in the target string
  • strspn — Calculate the length of the first substring in a string where all characters exist in the specified character set.
  • strstr — Find the first occurrence of a string
  • strtok — token split string
  • strtolower — Convert string to lowercase
  • strtoupper — Convert a string to uppercase
  • strtr — Convert the specified character
  • substr_compare — Binary safe comparison of strings (specified length compared from offset position)
  • substr_count — Count the number of occurrences of a string
  • substr_replace — Replace a substring of a string
  • substr — Returns a substring of a string
  • trim — remove whitespace characters (or other characters) at the beginning and end of a string
  • ucfirst — Convert the first letter of a string to uppercase
  • ucwords — Convert the first letter of each word in a string to uppercase
  • vfprintf — Write a formatted string to a stream
  • vprintf — Output formatted string
  • vsprintf — Returns a formatted string
  • wordwrap — breaks a string into a specified number of words


Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn