I host a website in Perth, Australia.
Website is for a group in Melbourne, Australia.
Perth is 3 hours behind melbourne, so when writing a record to the database, the now() function writes the time of the server in perth. But I need to write the time the event occured in melbourne.
I could just use DateAdd to subtract 3 hours from now(), but then when Daylight Savings finishes in Melbourne (Perth doesn't have Daylight savings), I need to subtract 4 hours from now(). The problem is, I can't work out how the server in Perth is not know Whether or not it is daylight savings time in melbourne.
I may be going about this wrong, but if anyone has any suggestions on how a server in one timezone can best know the current time in another timezone (factoring in daylight savings), I would love to hear it.
Many Thanks in advance.