Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.javascript > #18973
| Message-ID | <1768477.VDQZ9sSgU4@PointedEars.de> (permalink) |
|---|---|
| From | Thomas 'PointedEars' Lahn <PointedEars@web.de> |
| Organization | PointedEars Software (PES) |
| Date | 2013-03-22 16:44 +0100 |
| Subject | Re: how to use MakeTime()? |
| Newsgroups | comp.lang.javascript |
| References | <35b1cc53-fb63-46e9-8f4d-b9880c86fdc3@googlegroups.com> <ca7b99dc-1ef7-442f-9332-f298c6c4d22e@5g2000yqz.googlegroups.com> |
Scott Sauyet wrote:
> Jim Michaels wrote:
>> I am trying to use MakeTIme(), MakeDay(), and MakeDate().
>> for a time zone offset, I am using
>> var tztc = MakeTime(parseInt(tza[0]), parseInt(tza[1]), 0, 0);//GMT-8 or
>> UTC-8 var day = MakeDay(time.getUTCFullYear(), time.getUTCMonth() + 1,
>> time.getUTCDate());
>> [ ... ]
>> but this is causing the debugger error "MakeTime is not defined".
>> I see this operator in older books. so it's very probable (?)
>> that the browser supports it, but if so, how? it's related to the
>> Date object. [ ... ]
>
> First off, the quality of Javascript books is notoriously poor,
> especially that of older books.
A considerable part of that poor quality is due to the fact that the author
is describing a programming language that simply does not exist. In my
experience any text that contains the word “Javascript” or even “javascript”
(sic!) can only be of substandard quality, as its (original) author
evidently has (had) no clue what they are talking about. Texts containing
the “JavaScript” string, but in wrong context, such as “JavaScript
standard”, are only a little bit better.
<http://PointedEars.de/es-matrix>
> But the error message is pretty clear: That function is not defined.
> It's also not a property of the Date constructor function.
There is no good reason to believe that the latter would be relevant. If it
were the case, the code above could only work if “Date” was in the scope
chain, meaning “with”.
> In fact, it's not built into any Javascript environment I know of.
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
QED.
> Perhaps your book defines this function earlier?
Unlikely, unless it is a rip of the Specification.
> In any case, if you want to use a function such as this, you'll have
> to include it in the environment yourself.
Probably he does not want to, though.
--
PointedEars
Twitter: @PointedEars2
Please do not Cc: me. / Bitte keine Kopien per E-Mail.
Back to comp.lang.javascript | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
how to use MakeTime()? Jim Michaels <jmichae3@yahoo.com> - 2013-03-21 18:36 -0700
Re: how to use MakeTime()? Scott Sauyet <scott.sauyet@gmail.com> - 2013-03-21 21:04 -0700
Re: how to use MakeTime()? Jim Michaels <jmichae3@yahoo.com> - 2013-03-22 00:21 -0700
Re: how to use MakeTime()? Thomas 'PointedEars' Lahn <PointedEars@web.de> - 2013-03-22 16:44 +0100
Re: how to use MakeTime()? Scott Sauyet <scott.sauyet@gmail.com> - 2013-03-22 18:58 -0700
Re: how to use MakeTime()? Thomas 'PointedEars' Lahn <PointedEars@web.de> - 2013-03-22 16:30 +0100
Re: how to use MakeTime()? Dr J R Stockton <reply1300@merlyn.demon.co.uk.invalid> - 2013-03-24 18:36 +0000
csiph-web