Thursday, July 12, 2012

PHP: get the type of a variable

use gettype method:


$var1 = "Hello";
gettype($var1); // String


Reference:
http://php.net/manual/es/function.gettype.php

No comments: