php code help-- am not sure what is wrong here
Posted: Mon Nov 16, 2009 11:19 am
the following code return 0, it does not do the computation. Please can anybody help? am not sure if its the string convertion that is the problem.
Been trying out various options.
Pls help
public function Report_Target_Revenue($id){
$discount=0.85; //at 15%
$days=$this->Report_Duration($id); // returns 4
$daily_rate=$this->Report_Rate($id);// returns 28
$target_del=$this->Report_Target_Delegate($id);// returns 7
$target_revenue=$days * $daily_rate * $target_del * $discount;
return $target_revenue;
Been trying out various options.
Pls help
public function Report_Target_Revenue($id){
$discount=0.85; //at 15%
$days=$this->Report_Duration($id); // returns 4
$daily_rate=$this->Report_Rate($id);// returns 28
$target_del=$this->Report_Target_Delegate($id);// returns 7
$target_revenue=$days * $daily_rate * $target_del * $discount;
return $target_revenue;