Basic unit tests and additional documentation for wp_strip_all_tags().

props joehoyle.
fixes #25507.

Built from https://develop.svn.wordpress.org/trunk@27042


git-svn-id: http://core.svn.wordpress.org/trunk@26916 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
Andrew Nacin 2014-01-27 03:16:11 +00:00
parent 398ae265bc
commit c4e119d530

View File

@ -3569,6 +3569,10 @@ function normalize_whitespace( $str ) {
/**
* Properly strip all HTML tags including script and style
*
* This differs from strip_tags() because it removes the contents of
* the <script> and <style> tags. E.g. strip_tags( '<script>something</script>' )
* will return 'something'. wp_strip_all_tags will return ''
*
* @since 2.9.0
*
* @param string $string String containing HTML tags