The example text below the date popup and time input fields does not respect the configured time zone. Instead it uses the server OSes time zone. E.g. the server OS is set to Europe/Berlin(DST: +0200), the Drupal time zone is set to "Europe/Moscow" (DST: +0400) and the users time zone ist set to UTC. At 5:00 UTC one would expect, that the expample text below the time input field would be 05:00:00, but instead its 07:00:00 which is the servers OS time zone.
Attached is a patch that fixes the problem.
Test environment:
- PHP :5.2.6-1
- Server OS: Linux webtest 2.6.26-2-686 #1 SMP Thu Mar 26 01:08:11 UTC 2009 i686
- httpd: Apache/2.2.9 (Debian) PHP/5.2.6-1+lenny2 with Suhosin-Patch mod_python/3.3.1 Python/2.5.2 mod_perl/2.0.4 Perl/v5.10.0
| Comment | File | Size | Author |
|---|---|---|---|
| #3 | date_popup.diff | 2.28 KB | vitali04 |
| date_popup_module_1_42_2_1_2_52-0.txt | 1.33 KB | eric-alexander schaefer |
Comments
Comment #1
eric-alexander schaefer commentedComment #2
eric-alexander schaefer commentedComment #3
vitali04 commentedAlso value don't respect the time zone.
patch is attached.
I think we need to replace all date() and date_format() functions to date_format_date() for true TZ and locale
thanks
Attach is bit patch
Comment #4
eric-alexander schaefer commentedDidn't notice that because I always override the default value.
BTW: vitali04s patch contains my proposed change, so his patch should be applied.
Comment #5
ntcrportec commentedThis issue solved a problem i explain on the forum : http://drupal.org/node/608426 .
My problem was not just on example text, but in the pop-up himself, creating a trouble when i went to save a node.
With the replace of all date() and date_format() functions to date_format_date() in date_popup.module, all work fine now.
Thank you,
Comment #6
jennycita commented+1
Patch in Comment #3 did the trick for me.
Comment #7
kelu95310 commentedPatch in Comment #3 did the trick for me too.
thx
Comment #8
seren10pity commentedWorked perfectly for me too, thanks!
Comment #9
eric-alexander schaefer commentedComment #10
karens commentedThese changes are already in dev. There must have been a duplicate issue/patch.