I’ve encounter error at offset when using unserialize.
Notice: unserialize(): Error at offset 2 of 52 bytes in file.php on line 8881
So here’s the solution:
If you want to bring multi dimensional array to the next function , you have to serialize it and write to cookie .
This is how you can do it safely without losing offset.
//securely serialize your data $this->Cookie->write('nama_data_set', base64_encode(serialize($this->data)),false); //how to securely unserialize it on another function $data_yang_dibaca = unserialize(base64_decode($this->Cookie->read('nama_data_set')));



![Album Art for My Hero [January 1998]](http://userserve-ak.last.fm/serve/64s/69591230.png)
![Album Art for Numb [June 1993]](http://userserve-ak.last.fm/serve/64s/62577349.png)
