2012-12-25
Anyone who has used zencart1.5 knows that after logging on to the background, if there is no operation, it will automatically exit after 15 minutes. This is troublesome for background management.
This is an improvement of zencart1.5 in terms of security. The maximum setting in the background is 15 minutes. Many people want to delay the background login time.
So how can we leave the background login for a long time without automatically exiting? You can modify the code to extend the background administrator's session time.
Open the file includesfunctionssessions. php
/////////////////////
If (is_admin_flag === true ){
If (! $ Sess_life = (session_timeout_admin> 900? 900: session_timeout_admin )){
$ Sess_life = (session_timeout_admin> 900? 900: session_timeout_admin );
}
}
Here, session_timeout_admin is the administrator session time set in the background. The default value is 900 seconds at most.
Modify the above Code:
If (is_admin_flag === true ){
If (! $ Sess_life = (session_timeout_admin = 900? 9000: session_timeout_admin )){
$ Sess_life = (session_timeout_admin = 900? 9000: session_timeout_admin );
}
}
Then you can set the timeout time in the background-Basic settings-management dialog to 900 seconds. The above code is if 900 seconds is set, here, the session time is modified to 9000 seconds, which is equivalent to 150 minutes. If no operation is performed after logging on to the background, the system will log on again after 150 minutes, this time is enough. In this way, you do not need to log on to and enter the account password, especially during development.