Hi!
Here is the solution:-
open phpMyadmin
open dolphin DB
open sys_injection
click sql and run this query
INSERT INTO `sys_injections` (`name`, `page_index`, `key`, `type`, `data`, `replace`, `active`) VALUES
('head_inactive_redirect', '0', 'injection_head', 'php', 'replace me', '0', '1')
INSERT INTO `sys_injections` (`name`, `page_index`, `key`, `type`, `data`, `replace`, `active`) VALUES
('body_inactive_redirect', '0', 'injection_body', 'php', 'replace me', '0', '1')
edit the created row "name = head_inactive_redirect" and replace data field with below code replacing "replace me"
if (isMember() && !isAdmin()) {
echo '<script type="text/javascript">
var timer = 0;
function set_interval()
{
timer = setInterval("auto_logout()",300000);
}
function reset_interval()
{
if (timer != 0) {
clearInterval(timer);
timer = 0;
timer = setInterval("auto_logout()",300000);
}
}
function auto_logout()
{
window.location="logout.php";
}
</script>';
}
now hit "Go"
now edit the created row "name = body_inactive_redirect" and replace data field with below code replacing "replace me"
if (isMember() && !isAdmin()) {
echo 'onLoad="set_interval();" onmousemove="reset_interval();"'
}
hit "Go" and done. I don't think i need to remind you about clear the........:) enjoy
I have also attached a txt file with the above instruction if anyone need it.
Now what this does:
This script starts a timer when a page is loaded and reset it on every mouse movement. So, when a user will not move his mouse for 5 min this will redirect them to logout.php and what will happened after this you all know. This will not work for visitors(non-members) and admin they can do everything normally.
You all might be thinking that all my solutions comes from sys_injection but i can't do anything i love it...lol
so much to do....