WP hooks navigation: Home/browse • Actions index • Filters index
To save our bandwidth, we show only a snippet of code around each occurence of the hook. View complete file in SVN (without highlighting).
The best way to understand what a hook does is to look at where it occurs in the source code.
do_action( "hook_name" )
apply_filters( "hook_name", "what_to_filter" )
.Remember, this hook may occur in more than one file. Moreover, the hook's context may change from version to version.
This hook occurs 2 times in this file.
Line | Code |
---|---|
989 |
|
990 | foreach ($to_ncr as $entity => $ncr) { |
991 | $text = str_replace($entity, $ncr, $text); |
992 | } |
993 | return $text; |
994 | } |
995 |
|
996 | function wp_richedit_pre($text) { |
997 | // Filtering a blank results in an annoying <br />\n |
998 | if ( empty($text) ) return apply_filters('richedit_pre', ''); |
999 |
|
1000 | $output = $text; |
1001 | $output = convert_chars($output); |
1002 | $output = wpautop($output); |
1003 |
|
1004 | // These must be double-escaped or planets will collide. |
1005 | $output = str_replace('<', '&lt;', $output); |
1006 | $output = str_replace('>', '&gt;', $output); |
1007 |
|
1008 | return apply_filters('richedit_pre', $output); |
1009 | } |
1010 |
|
1011 | ?> |
1012 |
|