Summary | Calendar popup doesn't work in Safari (the OS X browser) |
Queue | Horde Base |
Queue Version | HEAD |
Type | Bug |
State | Resolved |
Priority | 2. Medium |
Owners | |
Requester | rwallace (at) thewallacepack (dot) net |
Created | 12/09/2004 (7524 days ago) |
Due | |
Updated | 12/11/2004 (7522 days ago) |
Assigned | 12/09/2004 (7524 days ago) |
Resolved | 12/11/2004 (7522 days ago) |
Github Issue Link | |
Github Pull Request | |
Milestone | |
Patch | No |
State ⇒ Resolved
cranky browser combination. Fixed in CVS.
if this is the correct behaviour according to the ECMA standard and
other browsers are wrong in the way they implement it. I'm not an
expert with javascript so I have no idea.
Couldn't we simply add more parameters to the href link in this case
to get it working? Something like
link.href = '?target=' + target + '&month=' + (month+1) + '&day=' +
day + '&year=' + year + '&callback=' + callback;
I don't know if we'd have to worry about encoding the target or not
because I don't think ? and & are going to be used to name form
elements by anyone. Makes it a little harder to get all the stuff you
need out of the URL, but it should work.
State ⇒ Assigned
but turning most javascript features off for KHTML.
State ⇒ Unconfirmed
Priority ⇒ 2. Medium
Type ⇒ Bug
Summary ⇒ Calendar popup doesn't work in Safari (the OS X browser)
Queue ⇒ Horde Base
horde/templates/javascript/open_calendar.js. The calendar displays
properly when opened, but when you try and select a date it fails and
sends you to the URL of the link (so like
http://mydomain.com/horde/kronolith/1) rather than updating the form
elements.
I did some digging and it looks like this is because the anonymous
onclick function is using variables defined in the openGoto() function
in which it is created, and in Safari those variables are out of
scope. So, in the day onclick function the target, month, day and
year variables are all out of scope so these lines
document.getElementById(target + '[month]').value = month + 1;
document.getElementById(target + '[day]').value = day;
document.getElementById(target + '[year]').value = year;
fail, the return false is never reached and the user is sent to an
invalid URL.