05-31-2013, 12:02 PM | #1 |
eBook DIYer
Posts: 111
Karma: 10
Join Date: Oct 2012
Location: Europe
Device: K4, KF HD 8.9, Readium
|
Meta charset removed by Sigil
When I "add a blank HTML file", this file contains the following code:
Code:
<?xml version="1.0" encoding="utf-8"?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <title></title> </head> As I am a good boy, I add the meta to the head section: Code:
<?xml version="1.0" encoding="utf-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="application/xhtml+xml; charset=utf-8" />
<title></title>
</head>
So, is it removed because it is redundant with the first line? Code:
<?xml version="1.0" encoding="utf-8"?> Thanks. |
05-31-2013, 12:36 PM | #2 |
Resident Curmudgeon
Posts: 73,983
Karma: 128903378
Join Date: Nov 2006
Location: Roslindale, Massachusetts
Device: Kobo Libra 2, Kobo Aura H2O, PRS-650, PRS-T1, nook STR, PW3
|
Tidy is the fault. Just leave it off.
|
05-31-2013, 12:45 PM | #3 |
A Hairy Wizard
Posts: 3,095
Karma: 18727053
Join Date: Dec 2012
Location: Charleston, SC today
Device: iPhone 11/X/6/iPad 1,2,Air & Air Pro/Surface Pro/Kindle PW & Fire
|
FWIW - I have never added the <meta> tag and kindlegen has never given me a warning if the ePub has passed flightcrew/epubcheck.
|
05-31-2013, 02:54 PM | #4 |
frumious Bandersnatch
Posts: 7,516
Karma: 18512745
Join Date: Jan 2008
Location: Spaniard in Sweden
Device: Cybook Orizon, Kobo Aura
|
That <meta> element is, I believe, completely superfluous. It might be OK for web pages, where a thousand charsets may be used, but in ePub you can only use utf-8 or utf-16 (and I guess the reading system must know how to tell which one it is).
|
05-31-2013, 05:51 PM | #5 |
Resident Curmudgeon
Posts: 73,983
Karma: 128903378
Join Date: Nov 2006
Location: Roslindale, Massachusetts
Device: Kobo Libra 2, Kobo Aura H2O, PRS-650, PRS-T1, nook STR, PW3
|
If I find that the XML does not render with UTF-8 in Firefox or Sigil, I use...
<meta content="http://www.w3.org/1999/xhtml; charset=utf-8" http-equiv="Content-Type"/> Right after the title and it works perfectly. |
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Little charset conversion typo | atordo | Recipes | 0 | 05-24-2012 03:21 PM |
360 Plus Filename, dirname charset problem | marf | PocketBook | 2 | 08-02-2011 09:40 PM |
Anyone else having charset issues with CM7? | jswinden | Nook Developer's Corner | 7 | 05-25-2011 04:18 PM |
Problem with ISO-8859-1 charset | cafedo | Recipes | 4 | 01-25-2011 04:14 AM |
Any way to apply calibre's "Series" (and number) meta-info from within Sigil...? | Vintage Season | Sigil | 2 | 07-02-2010 11:35 PM |