473,396 Members | 1,779 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,396 software developers and data experts.

DST/Summertime across the Atlantic

Since I need Central Europan Time, my servers are in Toronto,
and I cannot anymore follow Mr Bush'es influence on Canadian Time,
I made the following include .asp file,
valid for any server timezone location:

==================================
<%
nowGMT = DateAdd("h", TimezoneOffset, Now)
nowCET = DateAdd("h", 1, nowGMT)
If nowGMT>#2007-03-25 01:00# Then nowCET = DateAdd("h",2,nowGMT)
If nowGMT>#2007-10-28 01:00# Then nowCET = DateAdd("h",1,nowGMT)
If nowGMT>#2008-03-30 01:00# Then nowCET = DateAdd("h",2,nowGMT)
If nowGMT>#2008-10-26 01:00# Then nowCET = DateAdd("h",1,nowGMT)
%>

<script language='javascript' runat='server'>
var TimezoneOffset = new Date().getTimezoneOffset()/60;
</script>
===========================================

Why the one line if-then's and no elsif's?
Because I can more easily delete past year lines
and add new years say every two years.

Anyone with a simpler solution?

--
Evertjan.
The Netherlands.
(Please change the x'es to dots in my emailaddress)
Mar 12 '07 #1
2 1275
Evertjan. wrote:
Anyone with a simpler solution?
Always use GMT?

--
Dave Anderson

Unsolicited commercial email will be read at a cost of $500 per message. Use
of this email address implies consent to these terms.
Mar 12 '07 #2
Dave Anderson wrote on 12 mrt 2007 in
microsoft.public.inetserver.asp.general:
Evertjan. wrote:
>Anyone with a simpler solution?

Always use GMT?
Would be nice. Why dosn't VBS have GMT knowledge?

However:

1 others make use of those servers too.

2 UTC/GMT is not practical for my users.
--
Evertjan.
The Netherlands.
(Please change the x'es to dots in my emailaddress)
Mar 12 '07 #3

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

Similar topics

9
by: puzzled | last post by:
I'm trying to use a small gif of a Christmas tree as a horizontal divider across the screen (which could be any number of pixels wide). My attempt at doing this was basically like this: <img...
14
by: spencer | last post by:
My client is going through a large project to replace existing data warehouse physical infastructure which is running DB2 8.1.6. In the past we had a much more distributed environment where we had...
5
by: Corrine | last post by:
Given a backend on a network server and a frontend on a local computer, when is data pulled across the network? For example, does Rst.Recordcount pull data across the network? How about...
6
by: Damon Grieves | last post by:
Hi I just want to be sure I understand how the Access client works. If I have an Access back end with a million records on a server and an Access client. If the client is installed on the users pc...
0
by: domtam | last post by:
Hi everybody, As far as I understand, each worker process in a web garden (say, in IIS 6.0) has its own copy of Cache objects, static objects and Application(state) objects. In other words, they...
7
by: Doug | last post by:
An ASP.NET session cookie set on "www.mydomain.com" can not be accessed on "search.mydomain.com"; hence, a new session and cookie are being created on every sub-domain. This is occuring because...
9
by: McGeeky | last post by:
Is there a way to get a user control to remember its state across pages? I have a standard page layout I use with a header and footer as user controls. Each page uses the same layout by means of...
1
by: davidr | last post by:
Hi, I am using Divs with CSS to setup a layout for a site. I am using the <Div>s and style sheets below. I want the TopMenu to go across the entire top of the browser. It does go across the...
0
by: 2Barter.net | last post by:
Welcome to Atlantic City Fairfield Resorts Inbox Craig Oral Somerford to Thank, (bcc:Robin) More options 4:35 pm (0 minutes ago) Welcome to Atlantic City "CLICK" FairfieldResorts...
5
by: Jim Langston | last post by:
The output of the following program for me is: Same 0 1 2 Which is what I want. I just want to confirm this is well defined behavior, that a static local variable to a class function/method is...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...

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.