add "NO_SESSION" option to avoid saving session cookie when not needed