#1243 epub3: wrong format of dates in package.opf

output: ePub
closed-fixed
ePub (12)
5
2014-01-20
2012-07-08
compagnon
No

Hello !

In the package.opf (epub3), I can see the following date :
<meta property="dcterms:date">01/05/2010</meta>
from http://www.w3.org/TR/NOTE-datetime, the date should be <meta property="dcterms:date">2010-01-05</meta>

Thanks and regards

Discussion

  • compagnon
    compagnon
    2012-07-08

    example of opf file

     
    Attachments
  • Robert Stayton
    Robert Stayton
    2012-07-10

    The epub3 stylesheet currently just copies the content of any text in a info/date or info/pubdate element in the document. Work was started on a utility template named 'format.meta.date' in epub3/epub3-element-mods.xsl that would convert any date to the proper format, but that turned out to be a complicated problem for the general case, because there are lots of ways to represent dates. The current workaround it to put the proper format in your document's date or pubdate element.

     
    • summary: package.opf : wrong format of dates --> epub3: wrong format of dates in package.opf
     
  • Robert Stayton
    Robert Stayton
    2012-10-26

    I added a test to the templates processing date and pubdate elements to check the format of the element's date string. Now it warns when the date format does not match one of YYYY, YYYY-MM or YYYY-MM-DD. It is not feasible to convert every possible date string into this format (Europeans and Americans reverse the positions of month and day, for example).

     
  • Robert Stayton
    Robert Stayton
    2012-10-26

    • assigned_to: nobody --> bobstayton
    • status: open --> pending-fixed
     
  • Robert Stayton
    Robert Stayton
    2014-01-20

    • Status: pending-fixed --> closed-fixed