flyalaska Posted April 10, 2014 Report Posted April 10, 2014 I am running into a problem. I made a box to display the pilots total earnings. This is in layout.php. This is what I am using to display the money. <?php echo FinanceData::FormatMoney($userinfo->totalpay)?> Any idea what I am doing wrong? Quote
Moderators servetas Posted April 10, 2014 Moderators Report Posted April 10, 2014 I did not know that there was such a function on phpvms. On my website, i use: <?php echo $userinfo->totalpay; ?> <?php echo MONEY_UNIT; ?> Can you check it? Quote
mseiwald Posted April 10, 2014 Report Posted April 10, 2014 If this is on layout.tpl/layout.php you need to use <?php echo Auth::$userinfo->totalpay; ?> Quote
flyalaska Posted April 10, 2014 Author Report Posted April 10, 2014 If this is on layout.tpl/layout.php you need to use <?php echo Auth::$userinfo->totalpay; ?> That worked thank you, Do you how I can make it show with the decimal and full change? It shows 13814.1 want to show 13.814.10 Quote
skylineVirtual Posted April 24, 2014 Report Posted April 24, 2014 Try to use: <?php echo round(Auth::$userinfo->totally, 2); ?> Quote
mseiwald Posted April 24, 2014 Report Posted April 24, 2014 I would do it with number_format. <?php echo number_format(Auth::$userinfo->totalpay, 2, ',', '.'); ?> Quote
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.