Is this bad practice/can cause problems?
$_SESSION[\'stuff to keep\']
As opposed to calling str_replace() on the indices.
str_replace()
Seems like adding unnecessary whitespace in my opinion... I don't usually use spaces. If you do, though, make sure you quote the array keys.