Now using PHP session lifetime as default value for the JS config

This will fix the heartbeat when the session_lifetime config parameter
hasn't been set explicitly.

Please review @karlitschek @DeepDiver1975 @schiesbn @icewind1991