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.
Line | Code |
---|---|
412 | * @param string $blogname The site name |
413 | * @param string $blog_title The site title |
414 | * @param array $errors |
415 | */ |
416 | function signup_blog($user_name = '', $user_email = '', $blogname = '', $blog_title = '', $errors = '') { |
417 | if ( !is_wp_error($errors) ) |
418 | $errors = new WP_Error(); |
419 |
|
420 | // allow definition of default variables |
421 | $filtered_results = apply_filters('signup_blog_init', array('user_name' => $user_name, 'user_email' => $user_email, 'blogname' => $blogname, 'blog_title' => $blog_title, 'errors' => $errors )); |
422 | $user_name = $filtered_results['user_name']; |
423 | $user_email = $filtered_results['user_email']; |
424 | $blogname = $filtered_results['blogname']; |
425 | $blog_title = $filtered_results['blog_title']; |
426 | $errors = $filtered_results['errors']; |
427 |
|
428 | if ( empty($blogname) ) |
429 | $blogname = $user_name; |
430 | ?> |