Question #31   Submitted by Answiki on 05/03/2020 at 01:08:01 PM UTC

How to convert a string into integer in PHP?

Answer   Submitted by Answiki on 05/18/2020 at 03:05:56 PM UTC

In PHP, the function intval() get the integer value of a variable:

echo intval(39);	// 39
echo intval(3.9);  	//3
echo intval('28'); 	//28
echo intval('t'); 	//0

3 events in history
Answer by Answiki on 05/18/2020 at 03:05:56 PM

In PHP, the function intval() get the integer value of a variable:

echo intval(39);	// 39
echo intval(3.9);  	//3
echo intval('28'); 	//28
echo intval('t'); 	//0

Answer by Answiki on 05/03/2020 at 01:11:22 PM

The function intval() get the integer value of a variable:

echo intval(39);	// 39
echo intval(3.9);  	//3
echo intval('28'); 	//28
echo intval('t'); 	//0

Question by Answiki 05/03/2020 at 01:08:01 PM
How to convert a string into integer in PHP?
# ID Query URL Count

Icons proudly provided by Friconix.