mIRC Home    About    Download    Register    News    Help

Page 1 of 2 1 2 >
Topic Options
#36932 - 18/07/03 06:40 AM $ctime
ScatMan Offline
Hoopy frood

Registered: 06/05/03
Posts: 730
Ctime started at the same moment so how is that possible that it is different for every1 that has different timezone from you ??


Top
#36933 - 18/07/03 07:15 AM Re: $ctime
Pasmal Offline
Vogon poet

Registered: 07/12/02
Posts: 103
Loc: New Zealand
Because each timezone is a different time. In New Zealand, I'm 12 hours ahead of the UK (GMT). ctime/unix epoch started at 01/01/70 12:00:00. So to me, ctime started about 1750wks 1day 6hrs 12mins ago. Because the time is 6:12pm, 18/06/2003. But in the UK, the time is 6:12am, so in the UK, it's only been 1750wks, 18hrs, 12mins (or whatever) since epoch began.

I think that's about right...

Top
#36934 - 18/07/03 07:28 AM Re: $ctime
ScatMan Offline
Hoopy frood

Registered: 06/05/03
Posts: 730
my timezone is +2 hours from UK
in 1/1/1970 02:00:00 it started counting the ctime here
at the same moment, in UK, it was 00:00:00 and it start counting too
so it seems that until now, the duration here and there was the same

Top
#36935 - 18/07/03 10:34 AM Re: $ctime
KingTomato Offline
Planetary brain

Registered: 04/01/03
Posts: 3012
Loc: New Hampshire, USA
to put it in a simple term..
Quote:
Returns total number of seconds elapsed since 00:00:00 GMT, January 1, 1970 based on your system time.


Mainly if you have 5:00 am on your pc, and i have 7:00 am, mine is going to be a whole 2 hrs ((60 * 2) seconds) ahead of your ctime..
_________________________
-KingTomato

Top
#36936 - 18/07/03 10:39 AM Re: $ctime
ScatMan Offline
Hoopy frood

Registered: 06/05/03
Posts: 730
that "simple term" doesn't help me.. i want to know how it works.. read my second msg


Top
#36937 - 19/07/03 03:38 AM Re: $ctime
Pasmal Offline
Vogon poet

Registered: 07/12/02
Posts: 103
Loc: New Zealand
Try:

http://www.wikipedia.org/wiki/Unix_epoch (and then http://www.wikipedia.org/wiki/UTC, http://www.wikipedia.org/wiki/Epoch)

And

http://www.google.co.nz/search?hl=en&...y&meta=

Note that the UNIX epoch is based on 00:00:00 UTC on January 1 1970, itself a datetime that doesn't occur at the same instance everywhere in the world.

Top
#36938 - 19/07/03 07:41 AM Re: $ctime
ScatMan Offline
Hoopy frood

Registered: 06/05/03
Posts: 730
i'm sorry but i can't read it, it is too long..
anyone that already know it can help me ?
i don't need to know all this terms from the tutorial i just need an answer for my question


Top
#36939 - 19/07/03 09:21 AM Re: $ctime
Pasmal Offline
Vogon poet

Registered: 07/12/02
Posts: 103
Loc: New Zealand
Both my posts gave you information to answer your question.

Just because it is 'too long to read' does not make it an invalid answer. smirk

Top
#36940 - 19/07/03 11:03 AM Re: $ctime
ScatMan Offline
Hoopy frood

Registered: 06/05/03
Posts: 730
grrrr so can u answer my question here?
read my second post and that's what i can't figure out

Top
#36941 - 19/07/03 11:16 AM Re: $ctime
Hammer Offline
Hoopy frood

Registered: 07/12/02
Posts: 1321
Loc: Georgia, USA
What is so hard to understand? Your local $ctime is simply offset from $gmt by $timezone, plus or minus.Your timezone is GMT +2, so you would be subtracting 7200 seconds (2 hours) from your local $ctime to derive $gmt.
_________________________
DALnet: #HelpDesk and #m[color:#FF0000]IR[color:#EEEE00]C

Top
#36942 - 19/07/03 11:55 AM Re: $ctime
Watchdog Offline
Hoopy frood

Registered: 09/12/02
Posts: 2984
Loc: Hill End, NSW, Australia
Is there a way to convert a time given in a notice back to $ctime?
_________________________
Induced IRC
irc.induced.net

Top
#36943 - 19/07/03 12:19 PM Re: $ctime
Nobodi Offline
Vogon poet

Registered: 10/12/02
Posts: 191
Loc: Australia
//echo -ag $ctime(January 1 1970 10:00:00) returns 0 for me and should for you in NSW as well.

Top
#36944 - 19/07/03 01:42 PM Re: $ctime
Watchdog Offline
Hoopy frood

Registered: 09/12/02
Posts: 2984
Loc: Hill End, NSW, Australia
Close... Lets say I get a memo... and this is the "sent at" notice in the memo:

[22:37:07] -MemoServ- [Sent At: 19/07/03 11:39:06 GMT]

What I want to do is change the blue bit to $ctime. I can't find a way or even confirm if it is possible as $ctime isn't supplied by the server in this case. BTW, I have already modified the date to show the proper way, thank Christ for token identifiers lol.
_________________________
Induced IRC
irc.induced.net

Top
#36945 - 19/07/03 01:49 PM Re: $ctime
ScatMan Offline
Hoopy frood

Registered: 06/05/03
Posts: 730
yes, but it's not my question
think about it.. if the ctime here and GMT start counting the seconds at the same moment (but the time here and there wasn't the same, +2 hours) so how is that possible that until now it won't be the same ?


Top
#36946 - 19/07/03 01:55 PM Re: $ctime
ScatMan Offline
Hoopy frood

Registered: 06/05/03
Posts: 730
$ctime(19/07/03 11:39:06)

Top
#36947 - 19/07/03 02:01 PM Re: $ctime
lammkott Offline
Fjord artisan

Registered: 12/05/03
Posts: 215
Loc: Australia
Quote:

my timezone is +2 hours from UK
in 1/1/1970 02:00:00 it started counting the ctime here
at the same moment, in UK, it was 00:00:00 and it start counting too
so it seems that until now, the duration here and there was the same


The ctime in your location didn't start at '1/1/1970 02:00:00', it started at 1/1/1970 00:00:00 your local time, so when the ctime in the UK began, your local ctime would have been 2 hour into the count, or 7,200 seconds.
_________________________
- Jason

Top
#36948 - 19/07/03 02:27 PM Re: $ctime
Watchdog Offline
Hoopy frood

Registered: 09/12/02
Posts: 2984
Loc: Hill End, NSW, Australia
Okay thankyou.

With a little playing I came up with this which works beaut:

$time($calc($ctime($3 $4)+36000),HH:nn:ss)

With $3 and $4 equalling the date and time in the memo respectively.
_________________________
Induced IRC
irc.induced.net

Top
#36949 - 19/07/03 03:40 PM Re: $ctime
ScatMan Offline
Hoopy frood

Registered: 06/05/03
Posts: 730
aha
what about this
i tried $gmt(1/1/1970 03:00:00) but it returns the "1/1/1970 03:00:00" except returning the CTIME of it, why ?

Top
#36950 - 19/07/03 03:40 PM Re: $ctime
codemastr Offline
Hoopy frood

Registered: 12/12/02
Posts: 2809
Read the URLS you were given! They answer it, instead of reading it you just basically said "I'm too lazy" well then thats not our problem. We gave you the answer, you didn't want to take the time to read the answer, it's not our job to "dummy it up" for you. If you can't understand it, then it's simple you don't get an answer.

Top
#36951 - 19/07/03 03:49 PM Re: $ctime
ScatMan Offline
Hoopy frood

Registered: 06/05/03
Posts: 730
i'm not lazy and i'm really don't have time to read such a big tutorial when the answer to my question can be very short so i can understand it





Top
Page 1 of 2 1 2 >