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 |
---|---|
1901 | $edit_link = esc_url( add_query_arg( 'wp_http_referer', urlencode( esc_url( stripslashes( $_SERVER['REQUEST_URI'] ) ) ), "user-edit.php?user_id=$user_object->ID" ) ); |
1902 | } |
1903 | $edit = "<strong><a href=\"$edit_link\">$user_object->user_login</a></strong><br />"; |
1904 |
|
1905 | // Set up the hover actions for this user |
1906 | $actions = array(); |
1907 | $actions['edit'] = '<a href="' . $edit_link . '">' . __('Edit') . '</a>'; |
1908 | if ( $current_user->ID != $user_object->ID ) |
1909 | $actions['delete'] = "<a class='submitdelete' href='" . wp_nonce_url("users.php?action=delete&user=$user_object->ID", 'bulk-users') . "'>" . __('Delete') . "</a>"; |
1910 | $actions = apply_filters('user_row_actions', $actions, $user_object); |
1911 | $action_count = count($actions); |
1912 | $i = 0; |
1913 | $edit .= '<div class="row-actions">'; |
1914 | foreach ( $actions as $action => $link ) { |
1915 | ++$i; |
1916 | ( $i == $action_count ) ? $sep = '' : $sep = ' | '; |
1917 | $edit .= "<span class='$action'>$link$sep</span>"; |
1918 | } |
1919 | $edit .= '</div>'; |