[Xerte] Re: getTime oddness

Dave Burnett d_b_burnett at hotmail.com
Thu Mar 31 18:24:59 BST 2011


I agree.

But it must be the way Xerte parses it.
99% of the AS2 examples to prevent cacheing just use  "url?blah" + new Date().getTime();

Dave


Date: Thu, 31 Mar 2011 10:15:26 -0700
From: Paul.Swanson at harlandfs.com
To: xerte at lists.nottingham.ac.uk
Subject: [Xerte] Re: getTime oddness



That says to me that you need to create the new Date object before you can use getTime() on it. Seems logical to me, actually. From: xerte-bounces at lists.nottingham.ac.uk [mailto:xerte-bounces at lists.nottingham.ac.uk] On Behalf Of Dave Burnett
Sent: Thursday, March 31, 2011 9:01 AM
To: Xerte list
Subject: [Xerte] Re: getTime oddness 
Just for archives clarity.

myVar = new Date().getTime();
debug(myVar); //undefined

myVar = (new Date()).getTime();
debug(myVar); //1301590743993

From: Julian.Tenney at nottingham.ac.uk
To: Mike.Baker at RelianceInteractive.com; xerte at lists.nottingham.ac.uk
Date: Thu, 31 Mar 2011 16:48:47 +0100
Subject: [Xerte] Re: getTime oddnessIt's a runtime interpreter. It tokenises the code as it executes it. I've never fully understood the whole lexing / tokenising process: the code is in the XMLEngine.fla. There is the odd scenario it chokes on, but seven years on and must be several million lines of execution later, I'm happy to say it mostly works! I would have hought that is what's happening, yes, and why myVar = new Date().getTime(); works. From: xerte-bounces at lists.nottingham.ac.uk [xerte-bounces at lists.nottingham.ac.uk] On Behalf Of Mike Baker [Mike.Baker at RelianceInteractive.com]
Sent: 31 March 2011 16:16
To: 'Xerte discussion list'
Subject: [Xerte] Re: getTime oddnessBecause it forces the compiler to consider the phrase in the parens first. It may have been trying to do new (Date().getTime()); if the compiler tokenizes by whitespace first. Mike  From: xerte-bounces at lists.nottingham.ac.uk [mailto:xerte-bounces at lists.nottingham.ac.uk] On Behalf Of Dave Burnett
Sent: Thursday, March 31, 2011 8:24 AM
To: Xerte list
Subject: [Xerte] Re: getTime oddness 
debug((new Date()).getTime());

works with extra parentheses. 

?


From: Julian.Tenney at nottingham.ac.uk
To: xerte at lists.nottingham.ac.uk
Date: Thu, 31 Mar 2011 14:06:05 +0100
Subject: [Xerte] Re: getTime oddnessmyVar = new Date().getTime();debug(myVar); ?? From: xerte-bounces at lists.nottingham.ac.uk [xerte-bounces at lists.nottingham.ac.uk] On Behalf Of Dave Burnett [d_b_burnett at hotmail.com]
Sent: 31 March 2011 10:27
To: Xerte list
Subject: [Xerte] getTime oddness
Why would I get an undefined here?

debug(new Date().getTime());

new Date() gives me a date.
This message and any attachment are intended solely for the addressee and may contain confidential information. If you have received this message in error, please send it back to me, and immediately delete it. Please do not use, copy or disclose the information contained in this message or in any attachment. Any views or opinions expressed by the author of this email do not necessarily reflect the views of the University of Nottingham. 
This message has been checked for viruses but the contents of an attachment may still contain software viruses which could damage your computer system: you are advised to perform your own checks. Email communications with the University of Nottingham may be monitored as permitted by UK legislation. 

_______________________________________________ Xerte mailing list Xerte at lists.nottingham.ac.uk http://lists.nottingham.ac.uk/mailman/listinfo/xerte This message and any attachment are intended solely for the addressee and may contain confidential information. If you have received this message in error, please send it back to me, and immediately delete it. Please do not use, copy or disclose the information contained in this message or in any attachment. Any views or opinions expressed by the author of this email do not necessarily reflect the views of the University of Nottingham. This message has been checked for viruses but the contents of an attachment may still contain software viruses which could damage your computer system: you are advised to perform your own checks. Email communications with the University of Nottingham may be monitored as permitted by UK legislation. 
_______________________________________________ Xerte mailing list Xerte at lists.nottingham.ac.uk http://lists.nottingham.ac.uk/mailman/listinfo/xerte This message and any attachment are intended solely for the addressee and may contain confidential information. If you have received this message in error, please send it back to me, and immediately delete it. Please do not use, copy or disclose the information contained in this message or in any attachment. Any views or opinions expressed by the author of this email do not necessarily reflect the views of the University of Nottingham. This message has been checked for viruses but the contents of an attachment may still contain software viruses which could damage your computer system: you are advised to perform your own checks. Email communications with the University of Nottingham may be monitored as permitted by UK legislation. 
_______________________________________________
Xerte mailing list
Xerte at lists.nottingham.ac.uk
http://lists.nottingham.ac.uk/mailman/listinfo/xerte

This message and any attachment are intended solely for the addressee and may contain confidential information. If you have received this message in error, please send it back to me, and immediately delete it.   Please do not use, copy or disclose the information contained in this message or in any attachment.  Any views or opinions expressed by the author of this email do not necessarily reflect the views of the University of Nottingham.

This message has been checked for viruses but the contents of an attachment
may still contain software viruses which could damage your computer system:
you are advised to perform your own checks. Email communications with the
University of Nottingham may be monitored as permitted by UK legislation. 		 	   		  
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.nottingham.ac.uk/pipermail/xerte/attachments/20110331/4eac08d9/attachment.html>


More information about the Xerte mailing list