Converting numbers using php

49 views Asked by At

How to convert non-integrated numbers like this: 415.822948 to be integrated exactly like: 415 using PHP?

1

There are 1 answers

3
Sander On BEST ANSWER

You can use the intval() function for this.

Here's an example:

echo intval(415.822948);

This will output: 415