Welcome to openkapow Sign in | Join
in Search
.

Which time does dateTime() return?

Last post 02-28-2007, 5:02 AM by KVA_KapowTech. 1 replies.
Sort Posts: Previous Next
  •  02-27-2007, 6:59 PM 8401

    Which time does dateTime() return?

    When tried in design mode, the dateTime() returns the correct local time.

    But when the robot is uploaded to the server, I get a totally diffrent time. What exactly does dateTime() return when the robot is launched from your server: your server time (it looks like a US West Coast time)? The time on the server of the fetched URL? In case it is your server time, do you have many servers in multiple time zones, or is this time unique?

    To get the time to my local zone, do I have to transform the time I get from dateTime()? In my profile on this site, I have specified a time zone in "Site Options". Does this have any influence on the result of dateTime() ?

    Filed under: , , ,
  •  02-28-2007, 5:02 AM 8412 in reply to 8401

    Re: Which time does dateTime() return?

    Hi,

    The dateTime() is tied to the system clock of the server which execute the robot. Hence a server running in the US and a server running in Germany would at the same point in time return different timestamps when the dateTime() is called.

    Currently all OpenKapow servers are located within the same physical location, and the system clocks should (to my information) be synchronized, but this might very well change in the future.

    To help you along, I have created a small REST service which return the current GMT time:

    http://service.openkapow.com/demo/curretngmttime.rest

    This will always return the GMT time, regardless of where it is called from, and where it is executed. Of cause you can update the returned timestamp to match your local timezone, or you can use this service as a basis for your own implementation.

    Kind regards,

    Kenneth Andersen

    Kapow Support Team
    The question is not:
    "Is it possible for a robot to ..." but rather:
    "How do I setup a robot to ..."
View as RSS news feed in XML
.
Copyright 2006, 2007 KapowTech.com All Rights Reserved Company | Contact | Terms | Privacy