calendar days are incorrect
portait - April 8, 2008 - 08:28
| Project: | Archive |
| Version: | 6.x-1.0 |
| Component: | Block |
| Category: | bug report |
| Priority: | normal |
| Assigned: | Unassigned |
| Status: | active (needs more info) |
Description
The block does not show the right dates corresponding to the days. Is this a bug?
Check out screenshot: http://i26.tinypic.com/23h0ojl.png

#1
Exactly the same problem: it seems any month starts always on Sunday (or the day of the week selected as the first day of the week in the admin section (admin/settings/date-time))
#2
What I'd like to do is rely on Calendar or Date modules to provide the code for the calendar part, as there're too many modules relying on a calendar that end up with broken code like this.
Also, since I'm not sure what language that is, I don't actually know what day of the week your settings say should start the week and what order those days are in. If you could provide those details, I could look into this.
#3
In my page (http://fcalzado.net) I have this settings:
Thanks for your work!!
#4
Que mal. Voy a mirar a este problema cuando puedo.
Si quieres un contestacion rapido crees que puedes mirar a calendar.module o date.module para un funcion que hacer un calendario...
Lo siento para mi espanol.
#5
although i'm using drupal 5.7 and archive-5.x-1.10. but it has the same problem.
try this patch, when you want to set up an "First day of the week" except "Sunday".
#6
Was there supposed to be a patch?
#7
sorry, i failed to attach the diff file.
and then paste it below.
--------------------------------------------------------------------------------
diff -urN archive.orig/archive.module archive/archive.module
--- archive.orig/archive.module 2008-04-28 10:59:57.000000000 +0900
+++ archive/archive.module 2008-06-07 12:28:29.000000000 +0900
@@ -115,6 +115,7 @@
list($start_year, $start_month) = explode(' ', format_date($timestamp, 'custom', 'Y m'));
$start = gmmktime( 0, 0, 0, (int)$start_month, 1, (int)$start_year);
$weekday = gmdate('w', $start) - $first_day_of_week;
+ if (gmdate('w', $start) == 0 && $first_day_of_week != 0) $weekday += 7;
$days_row = array();
// From http://www.theadminzone.com/forums/showthread.php?t=17490
--------------------------------------------------------------------------------
#8
mmm... now succeeded in attaching that file.
maybe i was deranged... :(