I run a 5.6 drupal installation, after the upgrade archive displays incorrectly the month, actually it shows January (2008) starting on Monday 1st.
- Links are working as they suppose to work and in their correct dates.
- Changing the first day of the week seems to have no effect (no changes on the month display, just changes the days header).
- Reverting to the 5.x-1.7 version eliminates the problem.

I don't know if it qualifies as a bug or if it's my own fault. I succesfully installed archive (5.x-1.8) over a fresh Drupal installation without noticiable problems.

Thanks for your time.

CommentFileSizeAuthor
#6 screenshot1.png63.88 KBjonne.freebase

Comments

Susurrus’s picture

After you've upgraded, did you go to admin/settings/archive and resubmit all the values?

st.dogbert’s picture

I did with my selected nodes. Now I've tried it marking all nodes without luck. It seems to be a localization problem. It works correctly in english (I've got custom es.po and gl.po files too). Is there anyway to reload my new edited .po files? Resubmiting the values seems to be insufficient. I've got direct access to database too if it's needed.

st.dogbert’s picture

Status: Active » Closed (fixed)

Sorry, stupid question, drupal newcomer here. I'll edit and reload my files and report.

st.dogbert’s picture

Status: Closed (fixed) » Active

It's the "Tue" header what's giving me the problems, whenever I try to translate it either by .po file or manually (managing strings) I find (in the Calendar) that January changes from "Tue 1st" to "Mon 1st".

I also found this error when I try to import from the original "archive-module.po" which I use to flush the other translations:

"The translation file archive-module.po contains an error: the plural formula could not be parsed."

Hope it helps.

Susurrus’s picture

Can you attach a screenshot? I don't fully understand what's going on. As for the import part, I'm not exactly sure what you're doing here. I have limited experience with the localization and internationalization features of Drupal, so I'm not going to be much help here.

jonne.freebase’s picture

StatusFileSize
new63.88 KB

I have the same issue, here's a screenshot. I put rainlendar next to it so you see what's wrong:
Feb 1st isn't a monday, but it's a friday. A fix would be much appreciated.

jonne.freebase’s picture

Category: support » bug
Status: Active » Needs review

Ok, I made a patch, you just need to change one line. (If there's anything not proper about this patch, let me know, i'm not sure how important the paths on top are).

If you can't work with patch files, here's what you need to do:
go to line 342 of patch.module

change:
$weekday = array_search(gmdate('D', $start), $day_titles);
into:
$weekday = gmdate('w', $start)-$first_day_of_week;

That's it.

The old line searched $day_titles for the string 'Fri' (in the case of february 2008), but if you use internationalisation that string is translated into 'vr' (or whatever it is in your language of choice), which meant it couldn't be found.

this is tested on a website in Dutch, with Monday set as the start of the week, but it should work with the other settings too.

Please add this patch (or use another fix) before you release a new version, as I hate maintaining custom patches ;)

Susurrus’s picture

Title: Failure after upgrade 5.x-1.7 -> 5.x-1.8 » Calendar block displays incorrectly for non-English locales
Status: Needs review » Fixed

I try to fix bugs as promptly as I can, though sometimes I don't have the time to figure out the problem. If someone provides a patch, and it works, I'm happy to commit it. Thanks for your help, now go grab 1.9.

Anonymous’s picture

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for two weeks with no activity.