I'm creating a new payment plugin on Viart 5.
As we know that on Payment Details Page always having a section call "Secure Options" that allow admin to select save or unsave Credit Card Number or Security Code.
In the payment plugin, Is there a way so that I can prevent the credit card info to store in the DB even that the admin have set it as "Save encrypted" ?
Thanks,
Son
Vito
6 Mar 2018 5:34 PM
Hello Son,
There is no such possibility as payment module always called after order was saved in database.
But you can clear all credit card data by running appropriate SQL query in your code to be sure it wasn't saved in database.
$sql = " UPDATE ".$table_prefix."orders SET cc_number=NULL,cc_security_code=NULL WHERE order_id=".$db->tosql($order_id, INTEGER);
$db->query($sql);
Thanks,
Vito
sonvo
7 Mar 2018 2:46 AM
Thanks Vito,
Actually, I don't wanna even send the credit card info to the backend.
So I'm trying to create a custom form to use instead of using the form of Viart.
But not sure if is there a way to do that custom form.