Filters the email confirmation URL generated for a contact. Use this to redirect confirmations through a custom landing page.
apply_filters( 'groundhogg/confirmation_url', $url, $contact );
You will receive the generated URL string and the Contact object.
Example
add_filter( 'groundhogg/confirmation_url', 'my_extension_custom_confirm_url', 10, 2 );
/**
* Add a redirect parameter to the confirmation URL.
*
* @param string $url
* @param \Groundhogg\Contact $contact
*
* @return string
*/
function my_extension_custom_confirm_url( $url, $contact ) {
return add_query_arg( 'redirect_to', urlencode( home_url( '/welcome/' ) ), $url );
}
Was this helpful?
Let us know if this document answered your question. Thatβs the only way we can improve.
