Re: [PHP] Round help needed

2012-09-28 Thread Jay Blanchard
On 9/27/2012 10:05 PM, Chris Payne wrote: Hi everyone, I'm having one of those nights where nothing is working, please help What I have is this: $rounded_number = round($test, -3); Here's the problem i'm having, I need it to increment to the nearest 1000 but it seems to only work if the numbe

[PHP] output command and php

2012-09-28 Thread El Ale...
People good afternoon am using a system called the collects gammu sms my cell with a command "gammu getallsms" sms me when I pick up the following: gammu getallsms> messages.txt and I keep it in a text file with the following format: messages.txt folder, input code, tray number: +54025487555 S

Re: [PHP] A string question

2012-09-28 Thread Simon J Welsh
On 29/09/2012, at 1:29 AM, Chris Payne wrote: > Hi there everyone, > > I basically have the following code, which grabs the 3 numbers to the right: > > $input = "250705023"; > > $resta = substr($input, -3, 3); > > Then I manipulate them a little, but my question is - how, once i've used > the

Re: [PHP] Here's my rounding

2012-09-28 Thread Jim Giner
On 9/28/2012 2:11 AM, Simon J Welsh wrote: On 28/09/2012, at 6:08 PM, Chris Payne wrote: $test2 = '253177'; echo $tes2 . " rounded to: "; $rounded_number = round($test2,-3); echo $rounded_number; Is it SUPPOSED to happy a number is sent to this little system and it's SUPPOSED to round the num