<?php // suppose: $pri['base'] = 30000; $pri['com'] = 5000; // then $mst_per_off_base = bcmul($pri['base'],.01); // calculate 1% of the base price $gr[] = bcsub($pri['com'],$mst_per_off_base); // deduct the 1% off of the com echo array_sum($gr); // total of all after deduction
You have javascript disabled. You will not be able to edit any code.