You might want to redirect the user to a special page where they can see payment information, in case they want to pay through the Manual / Offline payment gateway.
This can be achieved using a code snippet:
add_action('pms_get_redirect_url', 'pmsc_redirect_after_manual_payment', 10, 2);
function pmsc_redirect_after_manual_payment( $url, $location ) {
if( !isset( $_POST['pay_gate']) || $_POST['pay_gate'] != 'manual' || !isset( $_POST['subscription_plans'] ) )
return $url;
$subscription_plan = pms_get_subscription_plan((int)$_POST['subscription_plans']);
if( !isset( $subscription_plan->id ) || $subscription_plan->price == 0 )
return $url;
else
return home_url('/payment-info');
}
Replace `/payment-info` with the slug of your own page.
In case you are using the Profile Builder form in order to register the user, you will also need to add these 2 lines of code to your website:
add_filter( 'wppb_after_success_email_confirmation_redirect', 'pmsc_redirect_after_manual_payment' );
add_filter( 'wppb_register_redirect', 'pmsc_redirect_after_manual_payment' );
Accept (recurring) payments, create subscription plans and restrict content on your website. Easily setup a WordPress membership site using Paid Member Subscriptions.
Get Paid Member SubscriptionsCombine the power of Profile Builder with Paid Member Subscriptions to set up user registration, memberships, and recurring revenue.
Get 25% off with the bundle