Answers for "sanitize_text_field"

PHP
0

sanitize_text_field

Check whether the string is a valid UTF-8 character, and remove all HTML tags.


$str = "<h2>Title</h2>";
sanitize_text_field( $str ); // it will return "title" without any HTML tags!
Posted by: Guest on July-09-2021

Code answers related to "sanitize_text_field"

Browse Popular Code Answers by Language