Add existing file error
#1  Derek R 10-20-2020, 02:51 PM
I have just installed the latest Sigil version 1.3.0. Whenever I try to add a particular .xhtml file nothing happens. On a second attempt I get a message saying that the file already exists in the book even though the window shows only the default code. Any ideas? Ultimately, I just had to copy and paste the file in the window and no errors were at any stage detected.

#2  JSWolf 10-20-2020, 02:57 PM
Try renaming it. Maybe it's because it's the same name as existing file.

#3  Derek R 10-20-2020, 03:07 PM
Thanks, but no, it doesn't want to load, even renamed. Other .xhtml files that I've loaded in the past (presumably successfully) are returning coding errors, but this one file won't load at all.

#4  Derek R 10-20-2020, 03:15 PM
Okay, I got it to load as an html file rather than a xhtml extension. I'm really a bit confused about the difference to be honest. But presumably it is fine to create epubs from html files anyway?

#5  KevinH 10-20-2020, 04:56 PM
No, epub needs xhtml but you can modify html to work.

That said, I could not follow what problem you are reporting.

Which Window shows only the default code? Re youtalking the BookBrowser or some other Window.

My guess is you are using a non-standard layout and the file was loaded, just not where you expected it to be.

#6  Derek R 10-20-2020, 05:25 PM
Hello, Kevin, I was talking about the main window that shows the code for the book. When you say you can modify html to work, what exactly do you mean? What I have done historically is to create an html file, wrap it in the basic xhtml doctype and tags -

<?xml version="1.0" encoding="utf-8"?>

<html xmlns="">

<p>my html here</p>

- save it as an xhtml file extension and then add it as an existing file in Sigil.
Am I doing something fundamentally wrong this way?

#7  Derek R 10-20-2020, 05:41 PM
PS I have just had my file validated on WC3 and yet it will not appear in Sigil by adding it as an existing file. Very odd.

#8  KevinH 10-20-2020, 06:09 PM
Are you saying it does not Appear in the BookBrowser window at all?

#9  hobnail 10-20-2020, 06:14 PM
I don't know why you're having a problem but what I do, which should sidestep it, is in Sigil's Book Browser right click and select Add Blank HTML File. Then replace the <p>(space entity)</p> line with everything between the two body tags in the file you're adding, copying the text from notepad or whatever. Ctl-C everything between the body tags in the original file, then in Sigil Ctl-V after selecting that <p>(space entity)</p> line (click on its line number). That ensures that you get a well formed html file up to the body tag.

#10  Derek R 10-20-2020, 06:44 PM
No, doesn't show up at all for whatever reason

  Next »  Last »  (1/3)
Today's Posts | Search this Thread | Login | Register