Filter: um_get_current_page_url

apply_filters( 'um_get_current_page_url', $page_url, $no_query_params ) → {string}

Filters current page URL.

Parameters:
Name Type Description
$page_url string

Current page URL.

$no_query_params bool

Ignore $_GET attributes in URL. false !== ignore.

Since:
  • 1.3.x
Source:
Returns:

Current page URL.

Type
string
Example

Add your custom $_GET attribute to all links.

function my_um_get_current_page_url( $page_url, $no_query_params ) {
    $page_url = add_query_arg( '{attr_value}', '{attr_key}', $page_url ); // replace to your custom value and key.
    return $page_url;
}
add_filter( 'um_get_current_page_url', 'my_um_get_current_page_url', 10, 2 );