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 |
---|---|
135 | } |
136 |
|
137 | // Returns array with headers in $response[0] and body in $response[1] |
138 | function akismet_http_post($request, $host, $path, $port = 80, $ip=null) { |
139 | global $wp_version; |
140 |
|
141 | $akismet_ua = "WordPress/{$wp_version} | "; |
142 | $akismet_ua .= 'Akismet/' . constant( 'AKISMET_VERSION' ); |
143 |
|
144 | $akismet_ua = apply_filters( 'akismet_ua', $akismet_ua ); |
145 |
|
146 | $content_length = strlen( $request ); |
147 |
|
148 | $http_host = $host; |
149 | // use a specific IP if provided |
150 | // needed by akismet_check_server_connectivity() |
151 | if ( $ip && long2ip( ip2long( $ip ) ) ) { |
152 | $http_host = $ip; |
153 | } else { |