Fix apply_filters. Bug 777.
git-svn-id: https://develop.svn.wordpress.org/trunk@2198 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
4247199e8d
commit
6872bdba06
@ -890,14 +890,13 @@ function merge_filters($tag) {
|
||||
function apply_filters($tag, $string) {
|
||||
global $wp_filter;
|
||||
|
||||
$args = array($string) + array_slice(func_get_args(), 3);
|
||||
|
||||
merge_filters($tag);
|
||||
|
||||
if (isset($wp_filter[$tag])) {
|
||||
foreach ($wp_filter[$tag] as $priority => $functions) {
|
||||
if (!is_null($functions)) {
|
||||
foreach($functions as $function) {
|
||||
$args = array($string) + array_slice(func_get_args(), 3);
|
||||
$string = call_user_func_array($function, $args);
|
||||
}
|
||||
}
|
||||
@ -1744,4 +1743,4 @@ function wp_clearcookie() {
|
||||
setcookie('wordpresspass_' . COOKIEHASH, ' ', time() - 31536000, SITECOOKIEPATH);
|
||||
}
|
||||
|
||||
?>
|
||||
?>
|
||||
|
Loading…
Reference in New Issue
Block a user