Jump to content
Main menu
Main menu
move to sidebar
hide
Navigation
Main page
Current events
Recent changes
Random page
Help
Categories
LemonWiki共筆
Search
Search
Appearance
Log in
Personal tools
Log in
Pages for logged out editors
learn more
Contributions
Talk
Editing
List of PHP binary safe functions
Page
Discussion
English
Read
Edit
View history
Tools
Tools
move to sidebar
hide
Actions
Read
Edit
View history
General
What links here
Related changes
Special pages
Page information
Appearance
move to sidebar
hide
Warning:
You are not logged in. Your IP address will be publicly visible if you make any edits. If you
log in
or
create an account
, your edits will be attributed to your username, along with other benefits.
Anti-spam check. Do
not
fill this in!
List of PHP '''binary safe'''<ref>[https://en.wikipedia.org/wiki/Binary-safe Binary-safe - Wikipedia]</ref> functions. Briefly speaking, using binary safe functions to manipulate the string in Mandarin or other unicode string. {| class="wikitable sortable" |- ! Purpose !! Binary safe function !! '''NOT''' binary safe |- | "Return part of a string" || [https://www.php.net/manual/en/function.mb-substr.php mb_substr] || [https://www.php.net/manual/en/function.substr.php substr] |- | "Get string length" || [https://www.php.net/manual/en/function.mb-strlen.php mb_strlen] || [https://www.php.net/manual/en/function.strlen.php strlen] |- | "Convert a string to an array || [https://www.php.net/manual/en/function.mb-str-split.php mb_str_split] || [https://www.php.net/manual/en/function.str-split.php str_split] |- | "Count the number of substring occurrences" || [https://www.php.net/manual/en/function.mb-substr-count.php mb_substr_count] || [https://www.php.net/substr-count substr_count] |- | "Replace all occurrences of the search string with the replacement string" || [https://www.php.net/manual/en/function.str-replace.php str_replace] || |- | "Find the position of the first occurrence of a substring in a string" || [https://www.php.net/manual/en/function.mb-strpos.php mb_strpos] || [https://php.net/manual/en/function.strpos.php strpos] |- | "Replace text within a portion of a string" || [https://www.php.net/manual/en/function.substr-replace.php substr_replace] or [https://gist.github.com/JBlond/942f17f629f22e810fe3 mb_substr_replace] || |- | ... || ... || ... |} == References == <references /> [[Category:PHP]] [[Category:Programming]] [[Category:Web_Dev]]
Summary:
Please note that all contributions to LemonWiki共筆 are considered to be released under the Creative Commons Attribution-NonCommercial-ShareAlike (see
LemonWiki共筆:Copyrights
for details). If you do not want your writing to be edited mercilessly and redistributed at will, then do not submit it here.
You are also promising us that you wrote this yourself, or copied it from a public domain or similar free resource.
Do not submit copyrighted work without permission!
Cancel
Editing help
(opens in new window)