bprwg_ip_address

Filters the SERVER global reported remote address.

Description

apply_filters( 'bprwg_ip_address', (string) $server_remote_addr ); 

Parameters (1)

0. $server_remote_addr (string)
IP Address of the user being registered.

Usage

To run the hook, copy the example below.
  1. $server_remote_addr = apply_filters( 'bprwg_ip_address', $server_remote_addr ); 
  2.  
  3. if ( !empty( $server_remote_addr ) ) { 
  4.  
  5. // everything has led up to this point... 
  6.  
  7.  
The following example is for adding a hook callback.
  1. // define the bprwg_ip_address callback 
  2. function filter_bprwg_ip_address( $server_remote_addr ) { 
  3. // make filter magic happen here... 
  4. return $server_remote_addr
  5. }; 
  6.  
  7. // add the filter 
  8. add_filter( 'bprwg_ip_address', 'filter_bprwg_ip_address', 10, 1 ); 
To remove a hook callback, use the example below.
  1. // remove the filter 
  2. remove_filter( 'bprwg_ip_address', 'filter_bprwg_ip_address', 10, 1 ); 

Defined (1)

The filter is defined in the following location(s).

/includes/core.php  
  1. update_user_meta( $user_id, '_bprwg_ip_address', apply_filters( '_bprwg_ip_address', $_SERVER['REMOTE_ADDR'] ) );