The forum of the forums
Would you like to react to this message? Create an account in a few clicks or log in to continue.

Time spent online code (on members' profile)

3 posters

Go down

Time spent online code (on members' profile) Empty Time spent online code (on members' profile)

Post by MrMega Fri Sep 18 2009, 21:50

I need the code to it. The first link in the google page you see => here

Doesn't work.

Does anyone know the code for it? ankillien? rono?
MrMega
MrMega
Forumember

Male Posts : 981
Reputation : 11
Language : English, Polish, HTML, BBCode
Location : New York, United States

Back to top Go down

Time spent online code (on members' profile) Empty Re: Time spent online code (on members' profile)

Post by Guest Fri Sep 18 2009, 23:10

The php code your looking for would be

{TOTAL_TIME_MEMBER_LOGGED_IN}

Or

{TOTAL_TIME_LOGGED_IN}

depending on where you want to use it Smile

regards







Craig
avatar
Guest
Guest


Back to top Go down

Time spent online code (on members' profile) Empty Re: Time spent online code (on members' profile)

Post by RoNo Sat Sep 19 2009, 00:06

I don't have a code to add a timer to your profile.

Here is an alternative...

I thinks it's a good idea to let the user choose to see a timer or not.
Personally, I use a pop-up timer (to keep track of time spent working
on forums) so it isn't reset when reloading/returning to the page.

The pop-up looks like this:
Time spent online code (on members' profile) Timespent_popup2


1st: Create an Html page for the timer
Code:
<br>
<script language="JavaScript">
startday = new Date();
clockStart = startday.getTime();
function initStopwatch() {
var myTime = new Date();
return((myTime.getTime() - clockStart)/1000);
}
function getSecs() {
var tSecs = Math.round(initStopwatch());
var iSecs = tSecs % 60;
var iMins = Math.round((tSecs-30)/60); 
var sSecs ="" + ((iSecs > 9) ? iSecs : "0" + iSecs);
var sMins ="" + ((iMins > 9) ? iMins : "0" + iMins);
document.forms[0].timespent.value = sMins+":"+sSecs;
window.setTimeout('getSecs()',1000);
}
</script>
<body onLoad="window.setTimeout('getSecs()',1)">
<center>
<form>
<font size="2" FACE="Arial">Time spent here: </FONT><br><input size=5 name=timespent>
</form>
</center>
</body>
</html>

Next: Create a pop-up link for the timer and add the
link to your Homepage Message content box, Widget etc.
Code:
<a onclick="window.open('http://zone3.forumotion.com/Time-Spent-h24.htm', 'popup46', 'width=200,height=30,height=200,left=150,top=250'); return false" href="http://zone3.forumotion.com/Time-Spent-h24.htm" target="popup46"><strong>Popup Timer<strong></a>
It's not what you asked for... but it's the alternative I use.

My timer has just reminded me... I have to go!

Adios Time spent online code (on members' profile) Cowboy3
RoNo
RoNo
Active Poster

Male Posts : 1270
Reputation : 135
Language : English
Location : Laguna Beach, California

http://bf2mercenaries.forumotion.com/

Back to top Go down

Time spent online code (on members' profile) Empty Re: Time spent online code (on members' profile)

Post by MrMega Sat Sep 19 2009, 01:36

I want it to go to the profiles..

Thanks Placehold and Rono thumleft

Although I don't think PHP works in profile fields, does it? Although i'll give it a shot Smile
MrMega
MrMega
Forumember

Male Posts : 981
Reputation : 11
Language : English, Polish, HTML, BBCode
Location : New York, United States

Back to top Go down

Time spent online code (on members' profile) Empty Re: Time spent online code (on members' profile)

Post by MrMega Sun Sep 20 2009, 15:18

Bump
Up
My
Post
MrMega
MrMega
Forumember

Male Posts : 981
Reputation : 11
Language : English, Polish, HTML, BBCode
Location : New York, United States

Back to top Go down

Time spent online code (on members' profile) Empty Re: Time spent online code (on members' profile)

Post by MrMega Tue Sep 22 2009, 21:41

Forgot to bump this...anybody?
MrMega
MrMega
Forumember

Male Posts : 981
Reputation : 11
Language : English, Polish, HTML, BBCode
Location : New York, United States

Back to top Go down

Time spent online code (on members' profile) Empty Re: Time spent online code (on members' profile)

Post by MrMega Wed Sep 23 2009, 21:25

15 minutes early, but who's counting...
MrMega
MrMega
Forumember

Male Posts : 981
Reputation : 11
Language : English, Polish, HTML, BBCode
Location : New York, United States

Back to top Go down

Time spent online code (on members' profile) Empty Re: Time spent online code (on members' profile)

Post by MrMega Fri Sep 25 2009, 21:21

Really, someone...
MrMega
MrMega
Forumember

Male Posts : 981
Reputation : 11
Language : English, Polish, HTML, BBCode
Location : New York, United States

Back to top Go down

Time spent online code (on members' profile) Empty Re: Time spent online code (on members' profile)

Post by MrMega Mon Sep 28 2009, 02:37

Anybody at all?
MrMega
MrMega
Forumember

Male Posts : 981
Reputation : 11
Language : English, Polish, HTML, BBCode
Location : New York, United States

Back to top Go down

Time spent online code (on members' profile) Empty Re: Time spent online code (on members' profile)

Post by Sanket Tue Sep 29 2009, 15:13

I was trying this a while ago, but i was unable to create anything. Thats why i did not reply earlier. Sorry
Sanket
Sanket
ForumGuru

Male Posts : 48766
Reputation : 2830
Language : English
Location : Mumbai

Back to top Go down

Back to top

- Similar topics

 
Permissions in this forum:
You cannot reply to topics in this forum