june_c21 Posted November 15, 2007 Share Posted November 15, 2007 hi, in my database it appear 16.10 but why in report (output) it appear 16.1 ?? how to make it to 16.10? Quote Link to comment Share on other sites More sharing options...
axiom82 Posted November 15, 2007 Share Posted November 15, 2007 $value = 16.10; echo sprintf ('%.2f', $value); Quote Link to comment Share on other sites More sharing options...
june_c21 Posted November 15, 2007 Author Share Posted November 15, 2007 what's wrong with this line $pdf->Cell(20,6,('%.2f',$myrow1[0]),1,1,'C',0); Quote Link to comment Share on other sites More sharing options...
axiom82 Posted November 15, 2007 Share Posted November 15, 2007 $pdf->Cell(20,6,(sprintf('%.2f',$myrow1[0]),1,1,'C',0); Quote Link to comment Share on other sites More sharing options...
june_c21 Posted November 15, 2007 Author Share Posted November 15, 2007 thanks a lot Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.