Friday, January 11, 2013

PHP String Functions


Function
Description
Returns a string with backslashes in front of the specified characters
Returns a string with backslashes in front of predefined characters
Converts a string of ASCII characters to hexadecimal values
Alias of rtrim()
Returns a character from a specified ASCII value
Splits a string into a series of smaller parts
Converts a string from one Cyrillic character-set to another
Decodes a uuencoded string
Encodes a string using the uuencode algorithm
Returns how many times an ASCII character occurs within a string and returns the information
Calculates a 32-bit CRC for a string
One-way string encryption (hashing)
Outputs strings
Breaks a string into an array
Writes a formatted string to a specified output stream
Returns the translation table used by htmlspecialchars() and htmlentities()
Converts Hebrew text to visual text
Converts Hebrew text to visual text and new lines (\n) into <br />
Converts HTML entities to characters
Converts characters to HTML entities
Converts some predefined HTML entities to characters
Converts some predefined characters to HTML entities
Returns a string from the elements of an array
Alias of implode()
Returns the Levenshtein distance between two strings
Returns locale numeric and monetary formatting information
Strips whitespace from the left side of a string
Calculates the MD5 hash of a string
Calculates the MD5 hash of a file
Calculates the metaphone key of a string
Returns a string formatted as a currency string
Returns specific local information
Inserts HTML line breaks in front of each newline in a string
Formats a number with grouped thousands
Returns the ASCII value of the first character of a string
Parses a query string into variables
Outputs a string
Outputs a formatted string
Decodes a quoted-printable string
Quotes meta characters
Strips whitespace from the right side of a string
Sets locale information
Calculates the SHA-1 hash of a string
Calculates the SHA-1 hash of a file
Calculates the similarity between two strings
Calculates the soundex key of a string
Writes a formatted string to a variable
Parses input from a string according to a format
Replaces some characters in a string (case-insensitive)
Pads a string to a new length
Repeats a string a specified number of times
Replaces some characters in a string (case-sensitive)
Performs the ROT13 encoding on a string
Randomly shuffles all characters in a string
Splits a string into an array
Count the number of words in a string
Compares two strings (case-insensitive)
Finds the first occurrence of a string inside another string (alias of strstr())
Compares two strings (case-sensitive)
Locale based string comparison
Returns the number of characters found in a string before any part of some specified characters are found
Strips HTML and PHP tags from a string
Unquotes a string quoted with addcslashes()
Unquotes a string quoted with addslashes()
Returns the position of the first occurrence of a string inside another string (case-insensitive)
Finds the first occurrence of a string inside another string (case-insensitive)
Returns the length of a string
Compares two strings using a "natural order" algorithm (case-insensitive)
Compares two strings using a "natural order" algorithm (case-sensitive)
String comparison of the first n characters (case-insensitive)
String comparison of the first n characters (case-sensitive)
Searches a string for any of a set of characters
Returns the position of the first occurrence of a string inside another string (case-sensitive)
Finds the last occurrence of a string inside another string
Reverses a string
Finds the position of the last occurrence of a string inside another string (case-insensitive)
Finds the position of the last occurrence of a string inside another string (case-sensitive)
Returns the number of characters found in a string that contains only characters from a specified charlist
Finds the first occurrence of a string inside another string (case-sensitive)
Splits a string into smaller strings
Converts a string to lowercase letters
Converts a string to uppercase letters
Translates certain characters in a string
Returns a part of a string
Compares two strings from a specified start position (binary safe and optionally case-sensitive)
Counts the number of times a substring occurs in a string
Replaces a part of a string with another string
Strips whitespace from both sides of a string
Converts the first character of a string to uppercase
Converts the first character of each word in a string to uppercase
Writes a formatted string to a specified output stream
Outputs a formatted string
Writes a formatted string to a variable
Wraps a string to a given number of characters

No comments:

Post a Comment