Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save chaselivingston/9cc8e8341eb85d8a5f46b62e57e688a4 to your computer and use it in GitHub Desktop.
Save chaselivingston/9cc8e8341eb85d8a5f46b62e57e688a4 to your computer and use it in GitHub Desktop.
if ( !empty( $_SERVER['HTTP_INCAP_CLIENT_IP'] ) ) {
$forwarded_ips = explode( ',', $_SERVER['HTTP_INCAP_CLIENT_IP'] );
$_SERVER['REMOTE_ADDR'] = $forwarded_ips[0];
unset( $forwarded_ips );
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment