ecabrera Posted April 13, 2015 Share Posted April 13, 2015 ok im stuck at how to calculate the pay. for example how would i calculate 14 hours and 42mins * Pay Salary i tried this 14.42 * 15 = 216.3 but im pretty sure thats off by a few cents or dollars. Any idea how to go about it Quote Link to comment https://forums.phpfreaks.com/topic/295509-calculating-pay-x-hours/ Share on other sites More sharing options...
maxxd Posted April 13, 2015 Share Posted April 13, 2015 You need to convert the minutes into a decimal value. For instance, 14 hours, 30 minutes equates to 14.5 * 15 = 217.50. Quote Link to comment https://forums.phpfreaks.com/topic/295509-calculating-pay-x-hours/#findComment-1508919 Share on other sites More sharing options...
Solution Barand Posted April 13, 2015 Solution Share Posted April 13, 2015 You need ($hours + $minutes/60) * $pay 1 Quote Link to comment https://forums.phpfreaks.com/topic/295509-calculating-pay-x-hours/#findComment-1508925 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.