PHP HELP PLEASE

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
ardoa
Forum Newbie
Posts: 7
Joined: Tue Oct 05, 2010 6:49 am

PHP HELP PLEASE

Post by ardoa »

Code: Select all

<td <? if (count($arr_invoice_listing)) { echo "colspan=\"3\""; } else { echo "colspan=\"2\""; } ?> class="invoice-detailbelow">
								<?=system_showText(LANG_LABEL_MAKE_CHECKS_PAYABLE);?> <?=$invoice_company?>
								<br />
								<b><?=system_showText(LANG_QUESTIONS);?>:</b> <?=system_showText(LANG_PLEASECALL);?> <?=$invoice_phone?>
								<br />
								<strong style="font-size: 8pt;"><?=system_showText(LANG_MSG_THANK_YOU);?></strong>
							</td>
							<th colspan="2" class="invoice-total"><?=system_showText(LANG_LABEL_TOTAL);?>: <span><?=CURRENCY_SYMBOL?><?=format_money($invoiceObj->getString("amount"))?></span> -


<?php
$first_number = 550;
$second_number = $amount;
$sum_total = $second_number * $first_number;
print ($sum_total);
?>
&nbsp;Pesos


</th>
						</tr>
					</table>

				</td>

I need multiply a variable value <?=format_money($invoiceObj->getString("amount"))?> * 550 as you see, but it doesnt work.
please anyone can help???

thanks
User avatar
twinedev
Forum Regular
Posts: 984
Joined: Tue Sep 28, 2010 11:41 am
Location: Columbus, Ohio

Re: PHP HELP PLEASE

Post by twinedev »

From this code, I $amount is not set to anything, Make sure it is set before you use it (it may be in another part of the code you didn't post).

Right before you use it, do var_dump($amount) to make sure it is set to value you think it should be.

-Greg
Post Reply