added base65 encoding and decoding of the encrypted data

Also added session_regenerate_id(); to get a new session_id on page reload/refresh.
The algorithm is working every time now.