iceblox Posted December 13, 2008 Share Posted December 13, 2008 Hi all Im using money format to sort out my long numbers but is there any way i can get it to not round up the last digit? this is my number... 1.957 and this is the code im using ".number_format($finalsum, 2, '.', '')." Any ideas? Link to comment https://forums.phpfreaks.com/topic/136855-money-format/ Share on other sites More sharing options...
revraz Posted December 13, 2008 Share Posted December 13, 2008 And what do you want it to display, 1.95? Link to comment https://forums.phpfreaks.com/topic/136855-money-format/#findComment-714735 Share on other sites More sharing options...
iceblox Posted December 13, 2008 Author Share Posted December 13, 2008 Yeah hopefully.. Link to comment https://forums.phpfreaks.com/topic/136855-money-format/#findComment-714737 Share on other sites More sharing options...
DarkSuperHero Posted December 13, 2008 Share Posted December 13, 2008 have you thought of making your own function to cut off the extra numbers after 2nd significant number after the decimal? that would probably be the best solution....use a combination of explode() and substr() .... Link to comment https://forums.phpfreaks.com/topic/136855-money-format/#findComment-714813 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.