07-18-2011, 10:58 AM | #46 |
Wizard
Posts: 2,627
Karma: 406616
Join Date: Dec 2008
Location: Northern Virginia
Device: SurfacePro, SurfaceBook 2
|
Dale, I hope this is the section you were referencing:
<head> <title>With This Fling…</title> <link href="../Styles/page-template.xpgt" rel="stylesheet" type="application/vnd.adobe-page-template+xml" /> <link href="../Styles/9781459205581.css" rel="stylesheet" type="text/css" /> <meta content="urn:uuid:96d9b0eb-d6fe-4256-9022-c93a9539910b" name="Adept.expected.resource" /> <style type="text/css"> p.sgc-2 {text-indent: 0%;} h2.sgc-1 {text-indent: 0%;} </style> </head> I did delete the .xpgt file but the characters were already there. |
07-18-2011, 01:45 PM | #47 |
Grand Sorcerer
Posts: 11,470
Karma: 13095790
Join Date: Aug 2007
Location: Grass Valley, CA
Device: EB 1150, EZ Reader, Literati, iPad 2 & Air 2, iPhone 7
|
At the very top of the file put:
<?xml version="1.0" encoding="UTF-8"?> Dale |
Advert | |
|
07-18-2011, 02:04 PM | #48 | |
Wizard
Posts: 2,627
Karma: 406616
Join Date: Dec 2008
Location: Northern Virginia
Device: SurfacePro, SurfaceBook 2
|
Quote:
I changed the first line of one of the files, the one that read: <?xml version="1.0"?> to the one you gave me, saved it and exited. I tried to view it with Reader Library and it still had the other characters. When I brought it back up in Sigil, the line was back to the old code: <?xml version="1.0"?> . I have no idea why. If I don't bring the epub file up in Sigil, the original displays with the correct characters. When I bring it up in Sigil and save, the wrong characters are there (are they Ascii? - I don't know what to call them). |
|
07-18-2011, 02:36 PM | #49 | |
Grand Sorcerer
Posts: 11,470
Karma: 13095790
Join Date: Aug 2007
Location: Grass Valley, CA
Device: EB 1150, EZ Reader, Literati, iPad 2 & Air 2, iPhone 7
|
Quote:
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> Either should work but if both are in a file they must agree. Yes, you will need the fix in every file. Dale |
|
07-18-2011, 02:45 PM | #50 |
Wizard
Posts: 2,627
Karma: 406616
Join Date: Dec 2008
Location: Northern Virginia
Device: SurfacePro, SurfaceBook 2
|
Dale, There is another call to meta: <meta content="urn:uuid:96d9b0eb-d6fe-4256-9022-c93a9539910b" name="Adept.expected.resource" /> in the <head> section. Can I add a second call or do I have to add on to the first one?
<meta content="urn:uuid:96d9b0eb-d6fe-4256-9022-c93a9539910b" name="Adept.expected.resource" /> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> or <meta content="urn:uuid:96d9b0eb-d6fe-4256-9022-c93a9539910b" name="Adept.expected.resource" http-equiv="Content-Type" content="text/html; charset=UTF-8" /> |
Advert | |
|
07-18-2011, 02:49 PM | #51 | |
Grand Sorcerer
Posts: 11,470
Karma: 13095790
Join Date: Aug 2007
Location: Grass Valley, CA
Device: EB 1150, EZ Reader, Literati, iPad 2 & Air 2, iPhone 7
|
Quote:
Dale |
|
07-18-2011, 03:00 PM | #52 |
Wizard
Posts: 2,627
Karma: 406616
Join Date: Dec 2008
Location: Northern Virginia
Device: SurfacePro, SurfaceBook 2
|
Okay. That was just weird. I inserted a copy of the line you gave me in all of the html files associated with the book, saved and exited and brought the book up on Reader Library again. The book still had the wonky characters and when I brought it back up in Sigil, the line had been deleted from all of the files. Pretty strange.
|
07-18-2011, 07:43 PM | #53 | |
Grand Sorcerer
Posts: 11,470
Karma: 13095790
Join Date: Aug 2007
Location: Grass Valley, CA
Device: EB 1150, EZ Reader, Literati, iPad 2 & Air 2, iPhone 7
|
Quote:
Make a backup of your epub. In windows - start -> programs -> Accessories -> System Tools -> Character Map. Make sure a large map is available such as Arial. I have advanced view checked an Character set Unicode. (If you can't find this let me know and I will show you how to get the characters out of our wiki) Scroll down and get the left double quote mark (or the one you want) and then select it. (U201C) You will need this map to pick the substitue characters so leave it up. Now in sigil use code view on the first file and then use the find command to search for the funny character sequence (select and paste both characters in the find) Now in the replace tab cust and past the unicode character you found on the character map, that you want to replace it with. Set the replace choice to mulitple files and then replace all. Repeat these steps for each funny character sequence until you replace all of them with the correct curly quotes. Save the epub and it should be ok. Dale |
|
07-18-2011, 07:47 PM | #54 | |
Wannabe Connoisseur
Posts: 425
Karma: 2516674
Join Date: Apr 2011
Location: Geelong, Australia
Device: Kobo Libra 2, Kobo Aura 2, Sony PRS-T1, Sony PRS-350, Palm TX
|
Quote:
If you're using Calibre, it can do the first two and last two steps above (but you mention opening in Reader Library so I suspect that's not the case). That all said, I'd just edit the html files directly in Sigil... Cheers, Simon. |
|
07-18-2011, 08:11 PM | #55 | |
Wizard
Posts: 2,627
Karma: 406616
Join Date: Dec 2008
Location: Northern Virginia
Device: SurfacePro, SurfaceBook 2
|
Quote:
Dale, I can use Find/Replace to change the Ascii characters in the file. I was REALLY hoping there was an easier way to change them all without the one-on-one replace. Thank you so much for all your help today. |
|
07-18-2011, 11:04 PM | #56 | |
Wannabe Connoisseur
Posts: 425
Karma: 2516674
Join Date: Apr 2011
Location: Geelong, Australia
Device: Kobo Libra 2, Kobo Aura 2, Sony PRS-T1, Sony PRS-350, Palm TX
|
Quote:
I'm still confused by you saying that you change the first line of a (all?) html file to <?xml version="1.0" encoding="UTF-8"?> but that it doesn't seem to "stick" in the epub. If you skip opening in Reader Library and re-open straight away after editing with Sigil again is the line there correctly? I shouldn't think that Reader Library would modify the epubs, but I don't know for sure. Cheers, Simon. |
|
07-18-2011, 11:51 PM | #57 | |
Well trained by Cats
Posts: 29,804
Karma: 54830978
Join Date: Aug 2009
Location: The Central Coast of California
Device: Kobo Libra2,Kobo Aura2v1, K4NT(Fixed: New Bat.), Galaxy Tab A
|
Quote:
|
|
07-19-2011, 12:57 AM | #58 | |
Grand Sorcerer
Posts: 11,470
Karma: 13095790
Join Date: Aug 2007
Location: Grass Valley, CA
Device: EB 1150, EZ Reader, Literati, iPad 2 & Air 2, iPhone 7
|
Quote:
To do this you must open the first file and switch to code view. Then you can open the find/replace menu and enter the text to find (find the multiple character instance but pasting both characters together) and the replace with the correct unicode character by cutting and pasting as I described. If you have trouble finding the characters in Windows then you can also use the ones in our wiki. Look at page Special characters and scroll down until you find the character you want. The column titled Character shows it. Then highlight the character and use CTRL-C to copy it. Now, in the replace dialog of Sigil you can use CTRL-V to paste it in. Dale |
|
07-19-2011, 08:51 AM | #59 | |
Wizard
Posts: 2,627
Karma: 406616
Join Date: Dec 2008
Location: Northern Virginia
Device: SurfacePro, SurfaceBook 2
|
Quote:
The freed epub works fine in Reader Library before I bring it up in Sigil. Once I open it in Sigil, the ASCII characters appear. If I don't Save the file in anyway, the characters are gone but once I've saved the epub in Sigil, the ASCII characters remain. I really think Dale has it right but I don't know what to do other than to global replaces as Dale suggested or find another epub editor and see if that makes a difference. |
|
07-19-2011, 09:01 AM | #60 | |
Wizard
Posts: 2,627
Karma: 406616
Join Date: Dec 2008
Location: Northern Virginia
Device: SurfacePro, SurfaceBook 2
|
Quote:
|
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
PDF to EPUB No output file | pearlheartgtr | Conversion | 1 | 04-12-2011 01:03 AM |
EPUB output | kovidgoyal | Calibre | 920 | 02-05-2011 11:59 AM |
EPUB output justification | toki08 | Calibre | 10 | 01-08-2011 04:14 PM |
Formatting errors in Mobi output | agriainc | Calibre | 3 | 08-22-2010 10:16 AM |
epub output metadata | troymc | Calibre | 5 | 05-22-2010 12:23 AM |