Skip to content

Remove advice on HTML file extension #1294

Closed

Description

@dauwhe

I thought we had discussed this, but I can't find an issue.

Content Docs says

The XHTML Content Document filename SHOULD use the file extension .xhtml

I think we should delete this sentence, and remove the corresponding test from EPUBCheck. I think this annoys users without helping anyone else. And if you use file extensions to tell you anything about a file, you're going to have a bad time.

Activity

  1. mattgarrish commented on Nov 11, 2020

    @mattgarrish
    Member

    Maybe we should do this across the board. We also recommend file extensions for the package document, svg, pls lexicons and smil files.

  2. dauwhe commented on Nov 11, 2020

    @dauwhe
    ContributorAuthor

    Maybe we should do this across the board. We also recommend file extensions for the package document, svg, pls lexicons and smil files.

    Yes!

  3. mattgarrish commented on Nov 11, 2020

    @mattgarrish
    Member

    Ya, I wanted to remove these while retooling the conformance sections, but didn't want to get bogged down in a conformance change. I'll open a PR.

  4. mattgarrish commented on Nov 11, 2020

    @mattgarrish
    Member

    Proposed Solution

    Remove the recommended file extensions for Package Documents, XHTML Content Documents, PLS Lexicons and Media Overlay Documents.

    Add a note in the package document definition section to refer to the media type registration for more info about file properties.

  5. dauwhe commented on Nov 12, 2020

    @dauwhe
    ContributorAuthor

    Did some testing. Made the "Ivan nightmare" file where an XHTML content document used the file extension .svg. The resulting EPUB gives a warning in EPUBCheck, of course, but works in:

    1. Apple Books
    2. Calibre
    3. Adobe Digital Editions 3.0
    4. Thorium

    Interestingly, when I tried to convert the EPUB to a non-EPUB format, the conversion tool complained.

  6. mattgarrish commented on Nov 12, 2020

    @mattgarrish
    Member

    Epubcheck doesn't inspect the content to verify the media type, so it's the easiest to fool. Faking media types was a periodic suggestion in the idpf forums for avoiding fallback requirements.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    EPUB33Issues fixed in the EPUB 3.3 revisionSpec-EPUB3The issue affects the core EPUB 3.X Recommendation

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions