Skip to content
Docs
Get RestroPress

Filter

rpress_payment_get_ip_address_url

Updated
On this page

Filters the HTML link shown for an order's IP address.

Used on the order details screen to render the customer's IP address. The default is an anchor to ipinfo.io for that address, opening in a new tab.

Parameters#

ParameterTypeDescription
$provider_urlstringHTML link markup.
$ipstringThe IP address stored on the order.
$payment_idintOrder ID.

Return value#

string. HTML link markup.

Example#

function my_ip_lookup_link( $link, $ip, $payment_id ) {
	return '<a href="' . esc_url( 'https://example.com/ip/' . $ip ) . '" target="_blank">' . esc_html( $ip ) . '</a>';
}
add_filter( 'rpress_payment_get_ip_address_url', 'my_ip_lookup_link', 10, 3 );

Source#

Applied in:

  • includes/rp-core-functions.php (line 2699), in rpress_payment_get_ip_address_url()
Was this page helpful?