I have a view which encrypts the current pid from database and when a 'save' button is clicked, it will redirect to the other controller.
My URL is encrypted. So, the 3rd segment in my URL is the pid, encrypted. So my URL will be:
http://localhost/profile/edit_entry/3YnwZhh5hLiYEB2ICaPUgZs.6Ydz8C1mbyiGoJnTcw34Ejuy0sgeIasI3C2fVxoZca4SgZ9mjKsqmX.l8otGrw--
But When I decode it and try to echo it, it won't echo anything.
My controller:
$pid = $this->uri->segment(3);
$pid = $this->encrypt->decode($pid);
echo "$pid";
Nothing happens. Any idea?