MyBB Community Forums

Full Version: Redirects users on random thread after xx idle time
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2
i was wandering that is it possibly to redirecting user to random thread after xx mins.. some time some user brows a single page more then 10 min, i don't want them to cut off as idle user,

i have see this mod on vBulletin.. Confused hope some i can get in mybb too
(2011-06-26, 12:38 AM)sibal Wrote: [ -> ]i was wandering that is it possibly to redirecting user to random thread after xx mins.. some time some user brows a single page more then 10 min, i don't want them to cut off as idle user,

i have see this mod on vBulletin.. Confused hope some i can get in mybb too

Why would you want to redirect users to random threads, I would find that annoying.
(2011-06-26, 02:05 AM)Jammerx2 Wrote: [ -> ]Why would you want to redirect users to random threads, I would find that annoying.

+1. What would the purpose be?
(2011-06-26, 02:05 AM)Jammerx2 Wrote: [ -> ]
(2011-06-26, 12:38 AM)sibal Wrote: [ -> ]i was wandering that is it possibly to redirecting user to random thread after xx mins.. some time some user brows a single page more then 10 min, i don't want them to cut off as idle user,

i have see this mod on vBulletin.. Confused hope some i can get in mybb too

Why would you want to redirect users to random threads, I would find that annoying.

See some time some of my user and also me open a thread and leave the forum for long time like 3hr and +, it will be great for me if i can make my idle user redirect to other thread act like they are active and i think my page visitor rank will be good .. i don't know the details but i have seen a forum did something same it's redirect 15 min idle user to index or other thread.. just cures.. please don't take it other-way Rolleyes
I wouldn't do that, it's not good to fake user activity.
(2011-06-26, 11:22 PM)Jammerx2 Wrote: [ -> ]I wouldn't do that, it's not good to fake user activity.

Confused thnx any way .. my English is not so good so i cant elaborate my speech Sad, how ever it would be good tho if the same thing can be made with a bot, and redirect idle user to index after they stay in a post or thread more then xxx min
Here is the function i was talking about that i have found in a site used, all i wanted to add some code that can only auto interval when user are idle

<script type = "text/javascript">

function reDirect() {
x = Math.ceil(Math.random() * 30); 
newPage = "forumdisplay.php?fid=" + x ;
window.location = newPage;
}

reDirect();

</script>
just give the header, meta refresh and set it 10 minutes (10*60 secons) Wink
the last opened thread by user will refresh automatically and give the cut idle time user back..

Open and edit showthread template.. refresh each 10 secons
<meta http-equiv="refresh" content="10">
{$headerinclude}

or give redirect to other page as you like
<meta http-equiv="refresh" content="10;url=http://yourforum.com/lazy-sleepy.html/">
(2011-06-27, 03:44 PM)FBI Wrote: [ -> ]just give the header, meta refresh and set it 10 minutes (10*60 secons) Wink
the last opened thread by user will refresh automatically and give the cut idle time user back..

Open and edit showthread template.. refresh each 10 secons
<meta http-equiv="refresh" content="10">
{$headerinclude}

or give redirect to other page as you like
<meta http-equiv="refresh" content="10;url=http://yourforum.com/lazy-sleepy.html/">


That is a good idea thnx now only remain the random thread things
ACP > Templates > Your theme templates > Showthread Templates > showthread > and add the following code just before the </head>

<script type="text/javascript">
	var urls = new Array("URL_1", "URL_2", "URL_3", "URL_4", "URL_5");
	function redirect()
	{
		window.location = urls[Math.floor(urls.length*Math.random())];
	}
	var temp = setInterval("redirect()", 10000);
</script>

You just need to change the URL_X to the desired thread URLs you want users to redirect to, and 10000 to the number of "Miliseconds" after the redirection occurs. Wink
(2011-06-27, 05:53 PM)Yaldaram Wrote: [ -> ]ACP > Templates > Your theme templates > Showthread Templates > showthread > and add the following code just before the </head>

<script type="text/javascript">
	var urls = new Array("URL_1", "URL_2", "URL_3", "URL_4", "URL_5");
	function redirect()
	{
		window.location = urls[Math.floor(urls.length*Math.random())];
	}
	var temp = setInterval("redirect()", 10000);
</script>

You just need to change the URL_X to the desired thread URLs you want users to redirect to, and 10000 to the number of "Miliseconds" after the redirection occurs. Wink

+1 Super this is what i needed ShyShyShy it's working great
Pages: 1 2