[support] patching drupal to account for daylight savings time

Jason Flatt drupal at oadaeh.net
Wed Aug 8 03:47:45 UTC 2007


On Tuesday 07 August 2007 12:36:26 Sarah Adams wrote:
> (I posted this question to the "Post installation" forum as well, not
> sure if I'm more likely to get a response there or here.)
>
> I am a recent convert to Drupal, and have just finished installing and
> configuring it for a site I'm developing. The only problem I had during
> the config process was setting the timezone. The site is in the Atlantic
> timezone (-0400), but when I choose this option currently, the time is
> one hour behind. I could set the timezone to -0500, but that wouldn't be
> correct, and I'd have to remember to change it twice a year.
>
> Anyway, I found this patch http://drupal.org/node/11077 which seems to
> do what I need, but I can't get the patch applied. So I have two questions:

There are actually several patches in that node, and you didn't mention which 
one you were using. I'm assuming you just grabbed the first patch and didn't 
actually read through the thread, or even the dates of the comments.

> 1) Right now I'm working on this site on my development server, so I
> have shell access and can apply the patch. What happens if I move the
> site to the client's host and don't have shell access in order to apply
> the patch?

Option 1: Work with the hosters to see if they will patch it for you.
Option 2: If you have FTP access, patch the files on your computer and upload 
them to where they need to be.
Option 3: Try to figure out how to do what you want done with a module.

> 2) The patch itself did not work (see below) - any idea why? I'm
> guessing maybe there is a more up-to-date version or something, but I
> have no idea where to look for it.

The patch was created for a version of Drupal before 5, and you're using 
version 5 or later. The files the patch is looking for are in different 
locations.

> can't find file to patch at input line 88
> Perhaps you used the wrong -p or --strip option?
> The text leading up to this was:
> --------------------------
>
> |Index: modules/node.module
> |===================================================================
> |RCS file: /cvs/drupal/drupal/modules/node.module,v
> |retrieving revision 1.403
> |diff -u -F^f -r1.403 node.module
> |--- modules/node.module 21 Sep 2004 18:43:54 -0000 1.403
> |+++ modules/node.module 26 Sep 2004 03:00:19 -0000

That file is now located in modules/node, so it should be 
modules/node/node.module (similarly with the other .module files). However, 
since it is for an older version of Drupal, I wouldn't take bets on it's 
actually working.

> TIA for any clues as to what I've done wrong!

Try reading the entire thread and finding a patch that is for the version of 
Drupal you are using (I'm assuming 5.2). The thread seems to span from 4.x to 
(now) 7.x. Also, since there is a lot of discussion in the thread with no 
real conclusion, I'd be very cautious in applying any patch.

-- 
Jason Flatt
http://www.oadaeh.net/
Father of Six:  http://www.flattfamily.com/ (Joseph, 14; Cramer, 12; Travis, 
10; Angela; Harry, 7; and William, 12:04 am, 12-29-2005)
Linux User:     http://www.xubuntu.org/
Drupal Fanatic: http://drupal.org/


More information about the support mailing list