Ecommerce Shopify WordPress Discussion

Add a replcement billing email if empty for credit card payment in WooCommerce

In WooCommerce, we have 2 payments methods, cash on delivery and credit card online. I have the following problem in Checkout page: The payment processor requires the email address from the customer, and it's mandatory. Then we have made the billing email field mandatory. But that makes a big drop in the conversion rate. So what I would like for the "email" field is: If the customer doesn't enter his email address, then we should autopopulate the field or the data sent to the payment processor with a generic replacement email like "contact@domain.com". And if the customer enters his email address, then everything will go through. I tried to use Add a replcement billing email if empty for credit card paymen in WooCommerce answer code, but didn't work for me. What i'm missing? Instead, there is a much more effective way: When the order is placed, on order creation, just before the payment, if the billing email is empty and the selected payment method is not COD, we set a temporary generated email address replacement as billing email. Then, just after the payment, we remove this email replacement. This temporary email replacement is generated from the customer complete name (or if there is no name, we generate an alphabetical random string) and from a domain name defined in the first function. This way, the payment gateway can't detect that the email is a fake.
TurboCommerce make the better internet purchasing globaly

Turbo Multi-language Translator

Make the better internet purchasing globaly

Turbosify SEO Speed Booster

5.0 (7) Free plan available
Get better conversions by improving store loading speed Installed

Turbo Multi-language Chat - AI Customer service in one hand

TurboCommerce make the better internet purchasing globaly
Our products

The help you need, when you need it

App by Turbo Engine

3 apps • 5.0 average rating

Turbosify Speed Booster

5.0 (7)
Get better conversions by optimizing shopify store Google page speed Installed

Turbosify Translator for Wordpress Woocommerce

5.0 (74) Free Wordpress Woocommerce Plugin
Translate your wordpress website to multiple language within 1 click, no configuration needed, no No technical required

Grow your business here

Whether you want to sell products down the street or around the world, we have all the tools you need.