The source of the error page displayed after I click on "confirm order" button in checkout says the following:
Code:
<br />
<b>Warning</b>: str_repeat() [<a href='function.str-repeat'>function.str-repeat</a>]: Second argument has to be greater than or equal to 0. in <b>C:\xampp\htdocs\PAC\shop\includes\modules\payment\cc.php</b> on line <b>259</b><br />
<br /><br />Email Error: SMTP Error: Data not accepted.<br /><br />
The section in the cc.php file which includes the offending line says:
Code:
line256 $len = strlen($_POST['cc_number']);
line257 $this->cc_middle = substr($_POST['cc_number'], 4, ($len-8));
line258 if ( (defined('MODULE_PAYMENT_CC_EMAIL')) && (zen_validate_email(MODULE_PAYMENT_CC_EMAIL)) ) {
line259 $order->info['cc_number'] = substr($_POST['cc_number'], 0, 4) . str_repeat('X', (strlen($_POST['cc_number']) - 8)) . substr($_POST['cc_number'], -4);
line260 }
line261 }
I'm too php-ignorant to know what's causing the problem here, or how to fix it. But since this section refers to 'MODULE_PAYMENT_CC_EMAIL', I thought maybe this could be the reason emails aren't being sent.
Hope this helps!
Bookmarks