If tutorials available on this website are helpful for you, please whitelist this website in your ad blocker😭 or Donate to help us ❤️ pay for the web hosting to keep the website running.
var_dump() function variable(s) के structure / information के बारे में बताता है। यह function variable में stored value उसका type , length etc. बताता है।
Array & Objects की property / values को यह function उनके structure के according show करता है। means अगर Array multidimensional है या Object किसी दुसरे Object को as a property contain करता है , var_dump() function उसे recursively show करता है।
PHP में यह काफी useful function है।
var_dump ( mixed $value , mixed ...$values );
mixed $value | required : variable जिसके बारे में आपको information चाहिए।
mixed ...$vars | optional : आप एक साथ कई variables check कर सकते हैं। हालाँकि कम से काम एक variable mandatory होता है।
File : php_var_dump.php
<?php
$a = array("Rahul Kumar", true , 0 , '', array(null, 'OK') );
var_dump($a);
?>
array(5) { [0]=> string(11) "Rahul Kumar" [1]=> bool(true) [2]=> int(0) [3]=> string(0) "" [4]=> array(2) { [0]=> NULL [1]=> string(2) "OK" } }
Hi ! I'm Rahul Kumar Rajput founder of learnhindituts.com. I'm a software developer having more than 4 years of experience. I love to talk about programming as well as writing technical tutorials and blogs that can help to others. I'm here to help you navigate the coding cosmos and turn your ideas into reality, keep coding, keep learning :)
Get connected with me. :) LinkedIn Twitter Instagram Facebook