In original core ZC code, any of the files under /includes/modules/ are called only after the session is started, so setting a value in one of those files should allow you to read that same value during subsequent visits using that same session.

If the value is set to an empty string, then (as mc8 mentioned above) clearly it's being set so your code is creating the entry, but then something in your own code is resetting it to empty.