Forum


Calc Builder Support

Calc Builder support
Forums
Public write access is disabled. Please login

Email - random errors 15.05.2012 05:09

Hello,

I am having a strange issue with the "send an email" feature and I am uncertain what is causing it. After the formula is calculated the send an email box pops up and when i enter an email address and click send a random error appears.

Sometimes the error is just three numbers like; 901, 121, etc and sometimes its the sum of the form. I does not say email sent or anything like that - but heres the storage in it all, the email does get sent.

Here is the code that I am using for cubic weight calculator, figured I add this just in case something was wrong here:

$cubic=$len1*$wit1*$hei1/166;
$actual=$act1;
$sum=$cubic;
if ($actual > $cubic)
echo ($sum=$actual);
else
echo ($sum);
$sum=number_format($sum,2);
$cubic=number_format($cubic,2);
$total=$rates1*$sum;
$total=number_format($total,2);

Thanks

Re: Email - random errors 15.05.2012 10:02

Hello,
checking your code, maybe you're getting that strange output due to the 'echo' instruction you're using. In fact, you don't need to use it at code section to have the values assigned properly. So,

if ($actual > $cubic)
echo ($sum=$actual);
else
echo ($sum);

is the same as

if ($actual > $cubic)
$sum=$actual;


and maybe you will get rid of that output containing values.

Hope this helps, best regards
Moonsoft Team
www.moonsoft.es

Re: Email - random errors 16.05.2012 18:51

That worked perfectly! Thank you very much :)

I'm not a PHP coder by any means, I knew it had to her something simple (for a coder anyway)!

Thanks again!!
Are you satisfied with our products/services/support?
Please help us to keep improving, add a review at  joomla extensions site and  magento connect

Our clients' feedback