Today, We want to share with you PHP print Array using print_r() Example.In this post we will show you PHP Simple print_r() function with Example, hear for How to Display Array Structure and Values in PHP we will give you demo and example for implement.In this post, we will learn about print associative array in php with an example.
PHP print Array using print_r() Example
There are the Following The simple About PHP print Array using print_r() Example Full Information With Example and source code.
As I will cover this Post with live Working example to develop PHP Array: Associative, Multidimensional, so the print associative array in php for this example is following below.
An array in PHP computer programming Data contains a total group of main data objects that are the same data type and data size. The PHP array can data main integers datatypes, characters as well as anything else with a main defined PHP data type.
How to Define and Print a PHP Print Array
$product_array = array(10,102,6,1920,50,102,2);
 => 10
 => 102
 => 6
 => 1920
 => 50
 => 102
 => 2
echo "<pre>";print_r($product_array);echo "</pre>";
Output – php array
Print_r() PHP Function
$Names = array ('a' => 'Atmiya', 'b' => 'jaydeep', 'c' => array ('Cade', 'Laptop'));
When the code is run, the results looks like this:
[a] => Atmiya
[b] => jaydeep
[c] => Array
 => Cade
 => Laptop
You can also read about AngularJS, ASP.NET, VueJs, PHP.
I hope you get an idea about PHP print Array using print_r() Example.
I would like to have feedback on my Pakainfo.com blog.
Your valuable feedback, question, or comments about this article are always welcome.
If you enjoyed and liked this post, don’t forget to share.
Here are some more FAQ related to this Article: