var_dump() function in PHP.

var_dump() displays information about variables in a simple, readable format. This function is very useful when debugging – providing a simple and easy way to display the current contents of one or more variables.

For simple scalar variables (such asbooleans,integers,strings, anddoubles), the type of the variable is printed, followed by an opening bracket, the value contained in the variable, and a closing bracket.

Resource pointers have their type (resource), ID number (such as 1, 2, or 45) and type of resource (such asdirorfile) displayed. The ID number assigned to a resource pointer reflects the order in which the resource pointer was created. (For example, the fifth resource pointer in a script has an ID number of 5.)

Arrays are printed as a list of keys and values, and have their typearray) printed at the top of the list.

Objects are handled in a fashion similar to that of arrays. The class of which the object is an instance is displayed, followed by the typeobject). After this, a list of the object’s member variables is printed.

_____________________________________________ SOURCES________

http://www.phpdig.net/ref/rn65re1375.html

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s