Opened 15 years ago

Closed 15 years ago

#8866 closed defect (fixed)

Hour format 09:00/21:00 in mythweb

Reported by: anonymous Owned by: Nicolas Riendeau
Priority: minor Milestone: 0.24
Component: Plugin - MythWeb Version: Master Head
Severity: medium Keywords: default time format
Cc: Ticket locked: no

Description

The hour format 09:00/21:00 in mythweb is not effective in Listings page

Change History (11)

comment:1 by robertm, 15 years ago

Status: newassigned

comment:2 by robertm, 15 years ago

Resolution: Invalid
Status: assignedclosed

Unable to reproduce, works fine for me.

comment:3 by anonymous, 15 years ago

My os is mandriva linux 64 bits.

To resole my problem I change the "generic_time" from %I:%M %p to %H:%M %p in the file mythweb/modules/_shared/lang/French.lang

Thanks you

comment:4 by Kenni Lund [kenni a kelu dot dk], 15 years ago

Resolution: Invalid
Status: closednew

comment:5 by Kenni Lund [kenni a kelu dot dk], 15 years ago

Owner: changed from Rob Smith to Nicolas Riendeau
Status: newassigned

Assigning to knight, as he will be updating the French translation within the next few weeks.

comment:6 by Nicolas Riendeau, 15 years ago

Keywords: default time format added
Milestone: unknown0.24
Status: assignedaccepted

I'll have to check with my colleagues who live in France what this should be set to.

(French.lang is MythWeb's translation file for France...)

From what I have just read what the reporter suggests might not fully respect France's time format.

Reporter, if you notice any other problems like this you can contact one of the French translators listed on http://www.mythtv.org/wiki/Translation either by email or on the website list as setting these things is under their responsibility.

(I happen to be one of those translators but that's the general rule...)

Nicolas

comment:7 by Rob Smith, 15 years ago

The date format is passed to php's date function. You can look at it's params at: http://www.php.net/manual/en/function.date.php

%I is "Whether or not the date is in daylight saving time" which is certainly incorrect.

Let me know if you have any problems figuring out the correct date format.

comment:8 by Jonathan Martens <jonathan@…>, 15 years ago

If you want to display the hours in a 24h notation, you should use %G (non-zero padded) or %H (zero padded) as suggested in comment 7.

comment:9 by Nicolas Riendeau, 15 years ago

kormoc, I thought it was strftime (http://php.net/manual/en/function.strftime.php) when the date needs to be localized...

Jonathan, that's a good point about the hour padding, I have forwarded the question to my fellow French translators to see what is most commonly used in France.

The format I found (for France) on the web is apparently good (replace the : with h) but according but, according to Gilles (a fellow French translator) it is not necessary to use it in this case.

As soon as I get Gilles' opinion on this I'll commit a fix...

Nicolas

comment:10 by gillessoixantequatorze@…, 15 years ago

He

I see that in the 0.22 but the modification arrived to late for 0.23.

I introduce this in the french translation files and in the french locale file

New format for the "generic_time" %H:%M

Gilles (French translation team)

Last edited 15 years ago by Nicolas Riendeau (previous) (diff)

comment:11 by Nicolas Riendeau, 15 years ago

Resolution: fixed
Status: acceptedclosed

This issue was resolved by ticket #8955.

The fix for this might be revisited later as the formatting is not exactly the one the French language translation team wanted to apply (namely not pad the hours with 0) but the only (somewhat undocumented) way to do this might not be portable/OS independent (only date lets one do this in a documented way and the time here is displayed using strftime)

The problem was that the time was shown in AM/PM format but it was otherwise OK (I for strftime != I for date).

As mentioned previously these kind of problems are better addressed by contacting the translators directly as we will not modify the content of a translation which is currently maintained.

Nick

PS: Gilles' signature was edited with permission to show who was actually replying to the ticket.

Note: See TracTickets for help on using tickets.