Hello,
I'm trying to serialize an array, then throw it into a url stream to pass it to a new page where I will then unserialize the array. When I pass it to the next page and do a print_r( $unserialized_array ), I get no values.
Here's the code I'm trying:
Page 1:
$array = array();
$array["a"] = "Foo";
$array["b"] = "Bar";
$array["c"] = "Baz";
$array["d"] = "Wom";
$test_array = serialize( $array );
Url string: <a href="page_2.php?serialized_array=<?=$test_array ?>" >
Page 2:
$this_code_array = array();
$this_code_array = unserialize( urldecode( $_REQUEST['serialized_array'] ) );
print_r( $this_code_array ); // will not print anything