Is it possible to var_dump or print_r a 3D SESSION array?
Posted: Wed Jan 31, 2007 9:40 am
Afternoon, I have a 3D session array and I can only view the values of individual keys if I echo them manually. I have the following code:
But this is only showing the array in a 2D sense.
Any ideas as to how I see every container within the array?
Regards,
Code: Select all
session_start();
$_SESSION[1]["test1"] = "sesh 1 test1";
$_SESSION[1]["test2"] = "sesh 1 test2";
$_SESSION[2]["test1"] = "sesh 2 test1";
var_dump($_SESSION); //
print_r($_SESSION); //
var_dump($_SESSION[1]); //
print_r($_SESSION[1]); // -- All these show items within a 2D sense of $_SESSION
var_dump($_SESSION[2]); //
print_r($_SESSION[2]); //
echo $_SESSION[1]["test1"]; // WorksAny ideas as to how I see every container within the array?
Regards,