Peace brother Sardar.
I do not know the exact time one can stay logged in. The moderator will tell you that.
For me ,if I am a while on the forum and I get logged out, I will save any work or posts I have made, then log in again .
It is then, only a matter of pasting the work done before being logged out.
Hope that helps.
GOD bless you.
Peace.