{"id":257,"date":"2016-07-28T08:45:08","date_gmt":"2016-07-28T08:45:08","guid":{"rendered":"https:\/\/barkhane.com\/php\/2016\/07\/28\/php-variable-built-in-functions\/"},"modified":"2024-03-03T15:01:43","modified_gmt":"2024-03-03T15:01:43","slug":"php-variable-built-in-functions","status":"publish","type":"post","link":"https:\/\/barkhane.com\/php\/php-variable-built-in-functions\/","title":{"rendered":"PHP Variable Built in Functions"},"content":{"rendered":"<h1 class=\"title\">What is Variable handling Functions in PHP ?<\/h1>\n<p>Variable handling function in <a href=\"https:\/\/barkhane.com\/php\/what-is-php\/\" target=\"_blank\" rel=\"noopener\">PHP<\/a> \u00a0are those function which maintain the property of \u00a0variable\u00a0and check for it,whether value of variable is correct or not according to requirement. There are various function for variable handling list is Given below .where $var is a\u00a0<a href=\"https:\/\/barkhane.com\/php\/php-variable-deceleration\/\" target=\"_blank\" rel=\"noopener\">variable<\/a><\/p>\n<table>\n<tbody>\n<tr>\n<td>boolval($var)<\/td>\n<td>Get the boolean value of a \u00a0<a href=\"https:\/\/barkhane.com\/php\/php-variable-deceleration\/\" target=\"_blank\" rel=\"noopener\">variable<\/a><\/td>\n<\/tr>\n<tr>\n<td>debug_zval_dump($var)<\/td>\n<td>Dumps a string representation of an internal zend value to output<\/td>\n<\/tr>\n<tr>\n<td>doubleval($var)<\/td>\n<td>Alias of floatval<\/td>\n<\/tr>\n<tr>\n<td>empty($var)<\/td>\n<td>Determine whether a\u00a0\u00a0<a href=\"https:\/\/barkhane.com\/php\/php-variable-deceleration\/\" target=\"_blank\" rel=\"noopener\">variable<\/a> \u00a0is empty<\/td>\n<\/tr>\n<tr>\n<td>floatval($var)<\/td>\n<td>Get float value of a \u00a0<a href=\"https:\/\/barkhane.com\/php\/php-variable-deceleration\/\" target=\"_blank\" rel=\"noopener\">variable<\/a><\/td>\n<\/tr>\n<tr>\n<td>get_defined_vars($var)<\/td>\n<td>Returns an array of all defined \u00a0<a href=\"https:\/\/barkhane.com\/php\/php-variable-deceleration\/\" target=\"_blank\" rel=\"noopener\">variable<\/a><\/td>\n<\/tr>\n<tr>\n<td>get_resource_type($var)<\/td>\n<td>Returns the resource type<\/td>\n<\/tr>\n<tr>\n<td>gettype($var)<\/td>\n<td>Get the type of a \u00a0<a href=\"https:\/\/barkhane.com\/php\/php-variable-deceleration\/\" target=\"_blank\" rel=\"noopener\">variable<\/a><\/td>\n<\/tr>\n<tr>\n<td>import_request_variables<\/td>\n<td>Import GET\/POST\/Cookie\u00a0\u00a0<a href=\"https:\/\/barkhane.com\/php\/php-variable-deceleration\/\" target=\"_blank\" rel=\"noopener\">variable<\/a> \u00a0into the global scope<\/td>\n<\/tr>\n<tr>\n<td>ntval($var)<\/td>\n<td>i Get the integer value of a \u00a0<a href=\"https:\/\/barkhane.com\/php\/php-variable-deceleration\/\" target=\"_blank\" rel=\"noopener\">variable<\/a><\/td>\n<\/tr>\n<tr>\n<td>is_array($var)<\/td>\n<td>Finds whether a\u00a0\u00a0<a href=\"https:\/\/barkhane.com\/php\/php-variable-deceleration\/\" target=\"_blank\" rel=\"noopener\">variable<\/a> \u00a0is an array<\/td>\n<\/tr>\n<tr>\n<td>is_bool($var)<\/td>\n<td>Finds out whether a \u00a0<a href=\"https:\/\/barkhane.com\/php\/php-variable-deceleration\/\" target=\"_blank\" rel=\"noopener\">variable<\/a>\u00a0is a boolean<\/td>\n<\/tr>\n<tr>\n<td>is_callable($var)<\/td>\n<td>Verify that the contents of a\u00a0\u00a0<a href=\"https:\/\/barkhane.com\/php\/php-variable-deceleration\/\" target=\"_blank\" rel=\"noopener\">variable<\/a> can be called as a function<\/td>\n<\/tr>\n<tr>\n<td>is_double($var)<\/td>\n<td>Alias of is_float<\/td>\n<\/tr>\n<tr>\n<td>is_float($var)<\/td>\n<td>Finds whether the type of a \u00a0<a href=\"https:\/\/barkhane.com\/php\/php-variable-deceleration\/\" target=\"_blank\" rel=\"noopener\">variable<\/a>\u00a0is float<\/td>\n<\/tr>\n<tr>\n<td>is_int($var)<\/td>\n<td>Find whether the type of a \u00a0variable\u00a0is integer<\/td>\n<\/tr>\n<tr>\n<td>is_integer($var)<\/td>\n<td>Alias of is_int<\/td>\n<\/tr>\n<tr>\n<td>is_long($var)<\/td>\n<td>Alias of is_int<\/td>\n<\/tr>\n<tr>\n<td>is_null($var)<\/td>\n<td>Finds whether a\u00a0\u00a0variable \u00a0is NULL<\/td>\n<\/tr>\n<tr>\n<td>is_numeric($var)<\/td>\n<td>Finds whether a\u00a0\u00a0variable \u00a0is a number or a numeric string<\/td>\n<\/tr>\n<tr>\n<td>is_object($var)<\/td>\n<td>Finds whether a\u00a0 \u00a0variable\u00a0is an object<\/td>\n<\/tr>\n<tr>\n<td>is_real($var)<\/td>\n<td>Alias of is_float<\/td>\n<\/tr>\n<tr>\n<td>is_resource($var)<\/td>\n<td>Finds whether a\u00a0\u00a0variable \u00a0is a resource<\/td>\n<\/tr>\n<tr>\n<td>is_scalar($var)<\/td>\n<td>Finds whether a\u00a0\u00a0variable \u00a0is a scalar<\/td>\n<\/tr>\n<tr>\n<td>is_string($var)<\/td>\n<td>Find whether the type of a\u00a0\u00a0variable \u00a0is string<\/td>\n<\/tr>\n<tr>\n<td>isset($var)<\/td>\n<td>Determine if a\u00a0\u00a0variable \u00a0is set and is not NULL<\/td>\n<\/tr>\n<tr>\n<td>print_r($var)<\/td>\n<td>Prints human-readable information about a \u00a0variable<\/td>\n<\/tr>\n<tr>\n<td>serialize($var)<\/td>\n<td>Generates a storable representation of a value<\/td>\n<\/tr>\n<tr>\n<td>settype($var)<\/td>\n<td>Set the type of a \u00a0variable<\/td>\n<\/tr>\n<tr>\n<td>strval($var)<\/td>\n<td>Get string value of a \u00a0variable<\/td>\n<\/tr>\n<tr>\n<td>unserialize($var)<\/td>\n<td>Creates a PHP value from a stored representation<\/td>\n<\/tr>\n<tr>\n<td>unset($var)<\/td>\n<td>Unset a given \u00a0variable<\/td>\n<\/tr>\n<tr>\n<td>var_dump($var)<\/td>\n<td>Dumps information about a \u00a0variable<\/td>\n<\/tr>\n<tr>\n<td>var_export($var)<\/td>\n<td>Outputs or returns a parsable string representation of a \u00a0variable<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n","protected":false},"excerpt":{"rendered":"<p>What is Variable handling Functions in PHP ? Variable handling function in PHP \u00a0are those function which maintain the property [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"site-sidebar-layout":"default","site-content-layout":"","ast-site-content-layout":"default","site-content-style":"default","site-sidebar-style":"default","ast-global-header-display":"","ast-banner-title-visibility":"","ast-main-header-display":"","ast-hfb-above-header-display":"","ast-hfb-below-header-display":"","ast-hfb-mobile-header-display":"","site-post-title":"","ast-breadcrumbs-content":"","ast-featured-img":"","footer-sml-layout":"","ast-disable-related-posts":"","theme-transparent-header-meta":"","adv-header-id-meta":"","stick-header-meta":"","header-above-stick-meta":"","header-main-stick-meta":"","header-below-stick-meta":"","astra-migrate-meta-layouts":"default","ast-page-background-enabled":"default","ast-page-background-meta":{"desktop":{"background-color":"var(--ast-global-color-4)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"tablet":{"background-color":"","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"mobile":{"background-color":"","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""}},"ast-content-background-meta":{"desktop":{"background-color":"var(--ast-global-color-5)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"tablet":{"background-color":"var(--ast-global-color-5)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"mobile":{"background-color":"var(--ast-global-color-5)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""}},"footnotes":""},"categories":[3],"tags":[],"class_list":["post-257","post","type-post","status-publish","format-standard","hentry","category-php"],"_links":{"self":[{"href":"https:\/\/barkhane.com\/php\/wp-json\/wp\/v2\/posts\/257","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/barkhane.com\/php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/barkhane.com\/php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/barkhane.com\/php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/barkhane.com\/php\/wp-json\/wp\/v2\/comments?post=257"}],"version-history":[{"count":0,"href":"https:\/\/barkhane.com\/php\/wp-json\/wp\/v2\/posts\/257\/revisions"}],"wp:attachment":[{"href":"https:\/\/barkhane.com\/php\/wp-json\/wp\/v2\/media?parent=257"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/barkhane.com\/php\/wp-json\/wp\/v2\/categories?post=257"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/barkhane.com\/php\/wp-json\/wp\/v2\/tags?post=257"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}