473,322 Members | 1,703 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,322 software developers and data experts.

Javascript will not display date correctly in FIREFOX, ok in EXPLORER

Hi. I am at a loss to decipher why the javascript on my web page:

http://www.psych.nmsu.edu/~jkroger/lab/index.html

does not display the date correctly in Firefox. Instead of "2005" for
the year,
it displays "105" ... however, in IE Explorer, it looks fine.
Thanks for any help,
Jim

Jul 23 '05 #1
34 2044
<kr****@princeton.edu> wrote in message
news:11*********************@z14g2000cwz.googlegro ups.com...
Hi. I am at a loss to decipher why the javascript on my web page:

http://www.psych.nmsu.edu/~jkroger/lab/index.html

does not display the date correctly in Firefox. Instead of "2005" for
the year,
it displays "105" ... however, in IE Explorer, it looks fine.
Thanks for any help,
Jim


Change
year = now.getYear();
to
year = now.getFullYear();
Jul 23 '05 #2
"McKirahan" <Ne**@McKirahan.com> wrote in message
news:ob********************@comcast.com...
<kr****@princeton.edu> wrote in message
news:11*********************@z14g2000cwz.googlegro ups.com...
Hi. I am at a loss to decipher why the javascript on my web page:

http://www.psych.nmsu.edu/~jkroger/lab/index.html

does not display the date correctly in Firefox. Instead of "2005" for
the year,
it displays "105" ... however, in IE Explorer, it looks fine.
Thanks for any help,
Jim


Change
year = now.getYear();
to
year = now.getFullYear();


getYear and getFullYear
http://www.quirksmode.org/js/datecompat.html

http://www.developersdex.com/asp/mes...2978&r=3701766
Jul 23 '05 #3
JRS: In article <11*********************@z14g2000cwz.googlegroups. com>,
dated Fri, 28 Jan 2005 17:18:15, seen in news:comp.lang.javascript,
kr****@princeton.edu posted :
Hi. I am at a loss to decipher why the javascript on my web page:

http://www.psych.nmsu.edu/~jkroger/lab/index.html

does not display the date correctly in Firefox. Instead of "2005" for
the year,
it displays "105" ... however, in IE Explorer, it looks fine.


Before posting to a newsgroup, you should read its FAQ; the FAQ for this
group is posted thrice a week, in two parts.

Indeed, you should read relevant FAQs before writing Web pages too; the
time you thus save includes your own.

Probably you are using method getYear which AIUI in various systems
can for current dates return 5, 105, or 2005.

Method getFullYear is available in current browsers (but be careful
if you are writing for the third world or backwoods colleges). And a
programmer can construct it from getYear and getTime . But if
that is the current date, then
(a) 2000 + getYear()%100 will do for quite a while
(b) telling the reader the current date is a waste of bandwidth.

--
© John Stockton, Surrey, UK. ?@merlyn.demon.co.uk Turnpike v4.00 IE 4 ©
<URL:http://www.jibbering.com/faq/> JL/RC: FAQ of news:comp.lang.javascript
<URL:http://www.merlyn.demon.co.uk/js-index.htm> jscr maths, dates, sources.
<URL:http://www.merlyn.demon.co.uk/> TP/BP/Delphi/jscr/&c, FAQ items, links.
Jul 23 '05 #4
Dr John Stockton wrote:
JRS: In article <11*********************@z14g2000cwz.googlegroups. com>,
dated Fri, 28 Jan 2005 17:18:15, seen in news:comp.lang.javascript,
kr****@princeton.edu posted :
Hi. I am at a loss to decipher why the javascript on my web page:

http://www.psych.nmsu.edu/~jkroger/lab/index.html

does not display the date correctly in Firefox. Instead of "2005" for
the year,
it displays "105" ... however, in IE Explorer, it looks fine.

Before posting to a newsgroup, you should read its FAQ; the FAQ for this
group is posted thrice a week, in two parts.


Really? Never seen it here. Perhaps it's sent via an email news feed?

--
Ed Mullen
http://edmullen.net
http://edmullen.net/moz.html
Jul 23 '05 #5
On Sun, 30 Jan 2005 14:30:05 -0500, Ed Mullen <ed@edmullen.net> wrote:

[Auto-posted FAQ]
Really? Never seen it here. Perhaps it's sent via an email news feed?


No. It's posted just before 1200 GMT[1] every Monday, Wednesday and
Friday. It has been for as long as I've read this group.

Mike
[1] Possibly +0100 in the summer. I don't have those posts on this machine.

--
Michael Winter
Replace ".invalid" with ".uk" to reply by e-mail.
Jul 23 '05 #6
Michael Winter wrote:
On Sun, 30 Jan 2005 14:30:05 -0500, Ed Mullen <ed@edmullen.net> wrote:

[Auto-posted FAQ]
Really? Never seen it here. Perhaps it's sent via an email news feed?

No. It's posted just before 1200 GMT[1] every Monday, Wednesday and
Friday. It has been for as long as I've read this group.

Mike
[1] Possibly +0100 in the summer. I don't have those posts on this machine.


Nope, sorry. Been reading this group since at least early 2003 and I've
never seen a FAQ posted. Again, perhaps it is automatically sent on the
mailing list but I'm not seeing it on
news://news.mozilla.org:119/netscape...ozilla.general using
Mozilla Suite Mail/News. I see messages here going back to 11/13/2004
and there's no FAQ among them.

--
Ed Mullen
http://edmullen.net
http://edmullen.net/moz.html
Jul 23 '05 #7
Ed Mullen <ed@edmullen.net> wrote in
news:ct*********@ripley.netscape.com:
Dr John Stockton wrote:

Before posting to a newsgroup, you should read its FAQ; the FAQ for
this group is posted thrice a week, in two parts.


Really? Never seen it here. Perhaps it's sent via an email news
feed?


This is heavily cross-posted. One of the other groups may indeed have a
weekly FAQ posted, but not here in netscape.public.mozilla.general

This is a classic example of why cross-posting is a bozo-no no.

Followups set to netscape.public.mozilla.general
--
}:-) Christopher Jahn
{:-( http://www.actorsplayhouse.org

"But we'll never survive!" "Nonsense. You're only saying that
because no one ever has." William Goldman, THE PRINCESS BRIDE
Jul 23 '05 #8
Ed Mullen wrote:
Michael Winter wrote: <snip>
No. It's posted just before 1200 GMT[1] every Monday, Wednesday
and Friday. It has been for as long as I've read this group.

<snip> Nope, sorry. Been reading this group since at least early 2003
and I've never seen a FAQ posted. Again, perhaps it is
automatically sent on the mailing list but I'm not seeing it on
news://news.mozilla.org:119/netscape...ozilla.general using
Mozilla Suite Mail/News. I see messages here going back to
11/13/2004 and there's no FAQ among them.


The extensive list of cross-posted groups is not being observed. The FAQ
in question is the one belonging to comp.lang.javascript (and it is
posted to the group as described).

Richard.
Jul 23 '05 #9
Richard Cornford wrote:
Ed Mullen wrote:
Michael Winter wrote:


<snip>
No. It's posted just before 1200 GMT[1] every Monday, Wednesday
and Friday. It has been for as long as I've read this group.


<snip>
Nope, sorry. Been reading this group since at least early 2003
and I've never seen a FAQ posted. Again, perhaps it is
automatically sent on the mailing list but I'm not seeing it on
news://news.mozilla.org:119/netscape...ozilla.general using
Mozilla Suite Mail/News. I see messages here going back to
11/13/2004 and there's no FAQ among them.

The extensive list of cross-posted groups is not being observed. The FAQ
in question is the one belonging to comp.lang.javascript (and it is
posted to the group as described).

Richard.


Ahhh! Excellent. Thank you.

--
Ed Mullen
http://edmullen.net
http://edmullen.net/moz.html
Jul 23 '05 #10
"Ed Mullen" <ed@edmullen.net> wrote in message
news:ct*********@ripley.netscape.com...
Michael Winter wrote:
On Sun, 30 Jan 2005 14:30:05 -0500, Ed Mullen <ed@edmullen.net> wrote:

[Auto-posted FAQ]
Really? Never seen it here. Perhaps it's sent via an email news feed?
No. It's posted just before 1200 GMT[1] every Monday, Wednesday and
Friday. It has been for as long as I've read this group. .... [1] Possibly +0100 in the summer. I don't have those posts on this
machine.
Nope, sorry. Been reading this group since at least early 2003 and I've
never seen a FAQ posted. Again, perhaps it is automatically sent on the
mailing list but I'm not seeing it on
news://news.mozilla.org:119/netscape...ozilla.general using Mozilla
Suite Mail/News. I see messages here going back to 11/13/2004 and there's
no FAQ among them.


I think the FAQ referred to may be on comp.lang.javascript, one of the list
of groups to which this thread was cross-posted.
--
David Biddulph
Jul 23 '05 #11
On 30.01.2005 13:51, Michael Winter wrote:
On Sun, 30 Jan 2005 14:30:05 -0500, Ed Mullen <ed@edmullen.net> wrote:

[Auto-posted FAQ]
Really? Never seen it here. Perhaps it's sent via an email news feed?


No. It's posted just before 1200 GMT[1] every Monday, Wednesday and
Friday. It has been for as long as I've read this group.

Mike
[1] Possibly +0100 in the summer. I don't have those posts on this machine.


Classic example of why x-posting is idiotic to say the least. Now you
got users confused over a FAQ that's posted to ONE group but not to the
other x-posted groups ... senseless waste of everybody's time and effort.

/dd
Jul 23 '05 #12
Ed Mullen wrote:
Michael Winter wrote:
On Sun, 30 Jan 2005 14:30:05 -0500, Ed Mullen <ed@edmullen.net> wrote:

[Auto-posted FAQ]
Really? Never seen it here. Perhaps it's sent via an email news feed?


No. It's posted just before 1200 GMT[1] every Monday, Wednesday and
Friday. It has been for as long as I've read this group.

Mike
[1] Possibly +0100 in the summer. I don't have those posts on this
machine.


Nope, sorry. Been reading this group since at least early 2003 and I've
never seen a FAQ posted. Again, perhaps it is automatically sent on the
mailing list but I'm not seeing it on
news://news.mozilla.org:119/netscape...ozilla.general using
Mozilla Suite Mail/News. I see messages here going back to 11/13/2004
and there's no FAQ among them.

Never seen it either....
Jul 23 '05 #13
David Biddulph wrote:
"Ed Mullen" <ed@edmullen.net> wrote in message
news:ct*********@ripley.netscape.com...
Michael Winter wrote:
On Sun, 30 Jan 2005 14:30:05 -0500, Ed Mullen <ed@edmullen.net> wrote:

[Auto-posted FAQ]
Really? Never seen it here. Perhaps it's sent via an email news feed?
No. It's posted just before 1200 GMT[1] every Monday, Wednesday and
Friday. It has been for as long as I've read this group.
...
[1] Possibly +0100 in the summer. I don't have those posts on this
machine.


Nope, sorry. Been reading this group since at least early 2003 and I've
never seen a FAQ posted. Again, perhaps it is automatically sent on the
mailing list but I'm not seeing it on
news://news.mozilla.org:119/netscape...ozilla.general using Mozilla
Suite Mail/News. I see messages here going back to 11/13/2004 and there's
no FAQ among them.

I think the FAQ referred to may be on comp.lang.javascript, one of the list
of groups to which this thread was cross-posted.

I HATE cross-posted messages. BOUND to cause confusion!
Jul 23 '05 #14
JRS: In article <ct*********@ripley.netscape.com>, dated Sun, 30 Jan
2005 14:30:05, seen in news:comp.lang.javascript, Ed Mullen
<ed@edmullen.net> posted :
Dr John Stockton wrote:
JRS: In article <11*********************@z14g2000cwz.googlegroups. com>,
dated Fri, 28 Jan 2005 17:18:15, seen in news:comp.lang.javascript,
kr****@princeton.edu posted :
Hi. I am at a loss to decipher why the javascript on my web page:

http://www.psych.nmsu.edu/~jkroger/lab/index.html

does not display the date correctly in Firefox. Instead of "2005" for
the year,
it displays "105" ... however, in IE Explorer, it looks fine.

Before posting to a newsgroup, you should read its FAQ; the FAQ for this
group is posted thrice a week, in two parts.


Really? Never seen it here. Perhaps it's sent via an email news feed?

But what do *you* mean by "here"?

If you had read the attribution which you quoted, you would have seen
exactly what I meant by "here". The signature of that article provided
a further clue.

Before responding to an article, read it all, including the significant
header lines and signature; and think about what you have read.
Remember that the responsibility for your outgoing newsgroups line is
yours and yours alone.

--
© John Stockton, Surrey, UK. ?@merlyn.demon.co.uk Turnpike v4.00 IE 4 ©
<URL:http://www.jibbering.com/faq/> JL/RC: FAQ of news:comp.lang.javascript
<URL:http://www.merlyn.demon.co.uk/js-index.htm> jscr maths, dates, sources.
<URL:http://www.merlyn.demon.co.uk/> TP/BP/Delphi/jscr/&c, FAQ items, links.
Jul 23 '05 #15
On 29.01.2005 17:44, Dr John Stockton wrote:

--- Original Message ---
JRS: In article <11*********************@z14g2000cwz.googlegroups. com>,
dated Fri, 28 Jan 2005 17:18:15, seen in news:comp.lang.javascript,
kr****@princeton.edu posted :
Hi. I am at a loss to decipher why the javascript on my web page:

http://www.psych.nmsu.edu/~jkroger/lab/index.html

does not display the date correctly in Firefox. Instead of "2005" for
the year,
it displays "105" ... however, in IE Explorer, it looks fine.


Before posting to a newsgroup, you should read its FAQ; the FAQ for this
group is posted thrice a week, in two parts.

Indeed, you should read relevant FAQs before writing Web pages too; the
time you thus save includes your own.

Probably you are using method getYear which AIUI in various systems
can for current dates return 5, 105, or 2005.

Method getFullYear is available in current browsers (but be careful
if you are writing for the third world or backwoods colleges). And a
programmer can construct it from getYear and getTime . But if
that is the current date, then
(a) 2000 + getYear()%100 will do for quite a while
(b) telling the reader the current date is a waste of bandwidth.


The correct answer was posted long before you posted your reply. YOU
need to read the group a little more often before you criticize others
dumbass.
Jul 23 '05 #16
On 31.01.2005 07:09, Dr John Stockton wrote:

--- Original Message ---
JRS: In article <ct*********@ripley.netscape.com>, dated Sun, 30 Jan
2005 14:30:05, seen in news:comp.lang.javascript, Ed Mullen
<ed@edmullen.net> posted :
Dr John Stockton wrote:
JRS: In article <11*********************@z14g2000cwz.googlegroups. com>,
dated Fri, 28 Jan 2005 17:18:15, seen in news:comp.lang.javascript,
kr****@princeton.edu posted :

Hi. I am at a loss to decipher why the javascript on my web page:

http://www.psych.nmsu.edu/~jkroger/lab/index.html

does not display the date correctly in Firefox. Instead of "2005" for
the year,
it displays "105" ... however, in IE Explorer, it looks fine.
Before posting to a newsgroup, you should read its FAQ; the FAQ for this
group is posted thrice a week, in two parts.
Really? Never seen it here. Perhaps it's sent via an email news feed?

But what do *you* mean by "here"?


If you know ANYthing about cross-posting then you'd maybe realize that
the poster is reading in a group that has never seen the FAQ or even
heard of it for that matter. You need to learn how to deal with
cross-posting and not be so rude. Maybe even be nice enough to give a
short explanation for the benefit of those that are reading in another
group.
If you had read the attribution which you quoted, you would have seen
exactly what I meant by "here". The signature of that article provided
a further clue.

Before responding to an article, read it all, including the significant
header lines and signature; and think about what you have read.
Remember that the responsibility for your outgoing newsgroups line is
yours and yours alone.


Take your own advice sometimes.
Jul 23 '05 #17
Bozo wrote:
<snip>
... . You need to learn how to deal with cross-posting and
not be so rude. Maybe even be nice enough to give a short
explanation for the benefit of those that are reading in
another group.

<snip>

Maybe that, or maybe just a suitable indicated URL for the online
version of the FAQ in question in a signature.

Richard.
Jul 23 '05 #18
John, I appreciate your suggestions re: FAQs. However, I, and many
others, just don't operate like that in my 100 hour work weeks. Some
have opinions about what's right and wrong in usenet (or is it really
Google)? I gave up with that a couple decades ago.

I ask a question in my rush, usually I get help, if not, oh well. If
you feel I (or others) waste your time, then you probably would save
lots of time by not answering. Nonetheless, I appreciate your helpful
response.

Jim

Jul 23 '05 #19
Sorry, Dr. John, but I have to respond again..

I just noticed you told me that providing the current date is a waste
of bandwidth.

People don't really take you as seriously as you wish they would, do
they?

Jim

Jul 23 '05 #20
Lee
kr****@princeton.edu said:

John, I appreciate your suggestions re: FAQs. However, I, and many
others, just don't operate like that in my 100 hour work weeks. Some
have opinions about what's right and wrong in usenet (or is it really
Google)? I gave up with that a couple decades ago.

I ask a question in my rush, usually I get help, if not, oh well. If
you feel I (or others) waste your time, then you probably would save
lots of time by not answering. Nonetheless, I appreciate your helpful
response.


You might get more done in that 100 hour work week, or might even
be able to cut it back a bit, if you learned to do research before
you ask. You usually get the answers much more quickly.

Jul 23 '05 #21
Lee
kr****@princeton.edu said:

Sorry, Dr. John, but I have to respond again..

I just noticed you told me that providing the current date is a waste
of bandwidth.


Can you explain why I would want your site to tell me the current date?
It's available in the toolbar of my display, or on the calendar on my
wall.

Jul 23 '05 #22
Hm, that's a tough one. I'll have to think about it, and get back to
you.

Thanks,
Jim

Jul 23 '05 #23
"Lee" <RE**************@cox.net> wrote in message
news:ct*********@drn.newsguy.com...
kr****@princeton.edu said:

Sorry, Dr. John, but I have to respond again..

I just noticed you told me that providing the current date is a waste
of bandwidth.


Can you explain why I would want your site to tell me the current date?
It's available in the toolbar of my display, or on the calendar on my
wall.


A few reasons "why":

a) To get the current date on a Windows PC you have to hold your mouse over
the time in the system tray.

b) When the page is printed, the date and time appears on the page even if
Page Setup doesn't.

c) Not everyone has a calendar handy.

Many things waste bandwidth; showing the date is the least of them.
P.S. Jim, I'd put a comma after the day re "Tuesday February 1, 2005".
Jul 23 '05 #24
Lee
McKirahan said:

"Lee" <RE**************@cox.net> wrote in message
news:ct*********@drn.newsguy.com...
kr****@princeton.edu said:
>
>Sorry, Dr. John, but I have to respond again..
>
>I just noticed you told me that providing the current date is a waste
>of bandwidth.


Can you explain why I would want your site to tell me the current date?
It's available in the toolbar of my display, or on the calendar on my
wall.


A few reasons "why":

a) To get the current date on a Windows PC you have to hold your mouse over
the time in the system tray.

b) When the page is printed, the date and time appears on the page even if
Page Setup doesn't.

c) Not everyone has a calendar handy.


The fact that I might not be wearing a watch is not a good reason
to walk up to me and tell me the time.

Your guess that I might not want to bother to lift my arm to look
at it is even less good.

Wouldn't the date that the content was created be more useful than
the date that you happened to print it?

Jul 23 '05 #25
"Lee" <RE**************@cox.net> wrote in message
news:ct*********@drn.newsguy.com...
McKirahan said:

"Lee" <RE**************@cox.net> wrote in message
news:ct*********@drn.newsguy.com...
kr****@princeton.edu said:
>
>Sorry, Dr. John, but I have to respond again..
>
>I just noticed you told me that providing the current date is a waste
>of bandwidth.

Can you explain why I would want your site to tell me the current date?
It's available in the toolbar of my display, or on the calendar on my
wall.

A few reasons "why":

a) To get the current date on a Windows PC you have to hold your mouse overthe time in the system tray.

b) When the page is printed, the date and time appears on the page even ifPage Setup doesn't.

c) Not everyone has a calendar handy.


The fact that I might not be wearing a watch is not a good reason
to walk up to me and tell me the time.


So anything thing that appears on a Web page is equivalent to walking up to
you and telling you; excellent logic.
Your guess that I might not want to bother to lift my arm to look
at it is even less good.
Since you might "not be wearing a watch", what will you be lifting your arm
to look at it?
Wouldn't the date that the content was created be more useful than
the date that you happened to print it?


Useful to whom?
All I suggested was that a "few reasons why" existed.

Whether or not you agree with any of them is immaterial.
Talk about wasting bandwidth ...


Jul 23 '05 #26
Lee
McKirahan said:

"Lee" <RE**************@cox.net> wrote in message
news:ct*********@drn.newsguy.com...
McKirahan said:
>
>"Lee" <RE**************@cox.net> wrote in message
>news:ct*********@drn.newsguy.com...
>> kr****@princeton.edu said:
>> >
>> >Sorry, Dr. John, but I have to respond again..
>> >
>> >I just noticed you told me that providing the current date is a waste
>> >of bandwidth.
>>
>> Can you explain why I would want your site to tell me the current date?
>> It's available in the toolbar of my display, or on the calendar on my
>> wall.
>>
>
>A few reasons "why":
>
>a) To get the current date on a Windows PC you have to hold your mouseover >the time in the system tray.
>
>b) When the page is printed, the date and time appears on the page evenif >Page Setup doesn't.
>
>c) Not everyone has a calendar handy.
The fact that I might not be wearing a watch is not a good reason
to walk up to me and tell me the time.


So anything thing that appears on a Web page is equivalent to walking up to
you and telling you; excellent logic.


The analogy that you seemed to miss concerns providing
unsolicited, irrelevant information.

Your guess that I might not want to bother to lift my arm to look
at it is even less good.


Since you might "not be wearing a watch", what will you be lifting your arm
to look at it?


Reconsider the meaning of the words "might not".

Wouldn't the date that the content was created be more useful than
the date that you happened to print it?


Useful to whom?


Um, anybody?

All I suggested was that a "few reasons why" existed.

Whether or not you agree with any of them is immaterial.
Talk about wasting bandwidth ...


I had intended it as a discussion of design practice. It's only
the attitude that any opinions other than yours are "immaterial"
that may make it a waste of bandwidth.

Jul 23 '05 #27
Bozo wrote:
If you know ANYthing about cross-posting then you'd maybe realize that
the poster is reading in a group that has never seen the FAQ or even
heard of it for that matter. You need to learn how to deal with
cross-posting and not be so rude. Maybe even be nice enough to give a
short explanation for the benefit of those that are reading in another
group.

John's point was that the address to find the FAQ, the group to which
the FAQ applies, the group *from* which John was posting and the subject
at hand were *all* included in his reply.

I'm afraid it is up to the OP to read the damn replies and be
responsible for his own posting - not for John to try and second-guess
his actual intentions. John's reply was concise, clear, informative,
with full references and every possible detail that could have been
asked for.
Jul 23 '05 #28
McKirahan wrote:
"Lee" <RE**************@cox.net> wrote in message
news:ct*********@drn.newsguy.com...
kr****@princeton.edu said:
Sorry, Dr. John, but I have to respond again..

I just noticed you told me that providing the current date is a waste
of bandwidth.
Can you explain why I would want your site to tell me the current date?
It's available in the toolbar of my display, or on the calendar on my
wall.


A few reasons "why":

a) To get the current date on a Windows PC you have to hold your mouse over
the time in the system tray.

But at least it *is* the date. There is no guarantee that the website is
even in my date-zone, never mind my time-zone, so it might be quite
wrong for me.
b) When the page is printed, the date and time appears on the page even if
Page Setup doesn't.
It is up to me what gets printed on my pages. If I choose date (and
time) I get the date and time it is printed on. If I get it from the
website, I most likely do not - I get what time it is
*where_the_web_server_is*, not where I is :)
c) Not everyone has a calendar handy.

If they don't, it is easy enough to get one and more reliable than using
someone else's computer somewhere else in the world.
Jul 23 '05 #29
"Mark Preston" <us****@nosource.co.uk> wrote in message
news:ct*******************@news.demon.co.uk...

[snip]
A few reasons "why":

a) To get the current date on a Windows PC you have to hold your mouse over the time in the system tray.

But at least it *is* the date. There is no guarantee that the website is
even in my date-zone, never mind my time-zone, so it might be quite
wrong for me.

b) When the page is printed, the date and time appears on the page even if Page Setup doesn't.

It is up to me what gets printed on my pages. If I choose date (and
time) I get the date and time it is printed on. If I get it from the
website, I most likely do not - I get what time it is
*where_the_web_server_is*, not where I is :)
c) Not everyone has a calendar handy.

If they don't, it is easy enough to get one and more reliable than using
someone else's computer somewhere else in the world.


This is client-side JavaScript!

You see that date and time of your computer when viewing the page.
Jul 23 '05 #30
JRS: In article <ct*******************@news.demon.co.uk>, dated Tue, 1
Feb 2005 16:01:15, seen in news:comp.lang.javascript, Mark Preston
<us****@nosource.co.uk> posted :
a) To get the current date on a Windows PC you have to hold your mouse over
the time in the system tray.

But at least it *is* the date. There is no guarantee that the website is
even in my date-zone, never mind my time-zone, so it might be quite
wrong for me.

Javascript does not know where the website, by which I suppose you mean
the server, is.

The date and time that it will show will be the current date and time,
either GMT/UTC or local, as the client computer has it - provided that
the programmers have not made any silly errors such as displaying in FFF
outside FFF-land, using uncorrected getYear, etc.

However, we do know that neither the web-site programmer nor the browser
programmer is really to be trusted; for example, IE4 & IE6 (as
delivered) get the Week Number wrong for three days every 28 years, as
shown in <URL:http://www.merlyn.demon.co.uk/vb-dates.htm>.

The real folly lies in the presumption that the user wants to be told
the date that his computer is set to (except for pages that use that
information, naturally).

<FAQENTRY> Never do something unrequested on a Web page - fancy
background, showing date and/or time, etc., unless there is reason to
expect it to be beneficial to the typical reader. </FAQENTRY>

--
© John Stockton, Surrey, UK. ?@merlyn.demon.co.uk Turnpike v4.00 MIME. ©
Web <URL:http://www.merlyn.demon.co.uk/> - w. FAQish topics, links, acronyms
PAS EXE etc : <URL:http://www.merlyn.demon.co.uk/programs/> - see 00index.htm
Dates - miscdate.htm moredate.htm js-dates.htm pas-time.htm critdate.htm etc.
Jul 23 '05 #31
Probably, but it would also let people see how lazy I am.
"Last updated, March 23, 1923...."
Jim

Jul 23 '05 #32
Dr John Stockton wrote:
JRS: In article <ct*******************@news.demon.co.uk>, dated Tue, 1
Feb 2005 16:01:15, seen in news:comp.lang.javascript, Mark Preston
<us****@nosource.co.uk> posted :
a) To get the current date on a Windows PC you have to hold your mouse over
the time in the system tray.

But at least it *is* the date. There is no guarantee that the website is
even in my date-zone, never mind my time-zone, so it might be quite
wrong for me.


Javascript does not know where the website, by which I suppose you mean
the server, is.

Does if its server-side Javascript. My bad - didn't read the OP.
Jul 23 '05 #33
Hi Richard. My name is Luciano from Aries Systems. I sent you a couple
of emails asking for permission to use your javascript scrolling
datagrid in our web application. I'm assuming I was filtered out as
spam. We we're very impressed with your work on the grid. We would be
sure to mention you everywhere your script is used. Could you please
send me an email with your response? Thank you.

*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!
Jul 23 '05 #34
Hi Richard. My name is Luciano from Aries Systems. I sent you a couple
of emails asking for permission to use your javascript scrolling
datagrid in our web application. I'm assuming I was filtered out as
spam. We we're very impressed with your work on the grid. We would be
sure to mention you everywhere your script is used. Could you please
send me an email with your response? Thank you.

*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!
Jul 23 '05 #35

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
by: Lawrence San | last post by:
I'm trying to test some simple JavaScript meant to speed up the display of my Web pages for readers using modems, but I have a fast DSL connection and I'm having trouble visualizing how effective...
4
by: zborisau | last post by:
Hey good people, I've been given a problem to solve recently - and stuck with the solution for a good 4 days already. i have a link which leads to popup window. the purpose of that popup...
16
by: Eric | last post by:
I have a user of a web application written in Java/JSP that is unable to login to the site simply because certain links on the page do not run when they are clicked. Other popups using Javascript...
2
by: joelkeepup | last post by:
Hi, I made a change this morning and now im getting an error that says either "a is undefined or null" or "e is undefined or null" the microsoft ajax line is below, I have no idea how to...
1
by: xtremebass | last post by:
Hello Bytes, i have a calender program which is created by using Javascript. when i execute that program using Internet Explorer,it works properly but when i tried in Mozilla firefox it didnt...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
1
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.