Are you first timer at lazacode.org? Why not join us and start exchange your programming knowledge with everyone. Register today!

PHP Arithmetic Operators

0 votes
4 views
added Mar 27 in PHP by LC Marshal Lieutenant (12,590 points)
edited Jul 20 by LC Marshal
//PHP multiplication operators

<div class="transaction-item transaction-price">
<?php
$psf  = "130";
$lot_size  = "14200";
$total_price = $lot_size * $psf; 
?>

<?php print $total_price; ?>  
</div>

2 Responses

0 votes
responded Mar 27 by LC Marshal Lieutenant (12,590 points)
edited Jul 20 by LC Marshal
<?php
  $lot_size  = $row['area_sqft'];
  $psf  = $row['unit_price_psf'];

  $total_price = $lot_size * $psf; 
?>
<?php print $total_price; ?> 
0 votes
responded Jul 20 by LC Marshal Lieutenant (12,590 points)
// To find what percentage of certain amount from total amount

<?php
    $percent_own = $paidAmt / $topay * 100;
?>
lazacode.org - Malaysia's programming knowledge sharing platform, where everyone can share their finding as reference to others.
...