![]() |
#1 |
Connoisseur
![]() Posts: 74
Karma: 10
Join Date: Jul 2023
Device: None
|
OPF contains missing or unrecognized media
Greetings, everyone.
I have not visited this forum since September of 2023, when, with help from you all, I completed my first ePub project. That ePub is here: https://drive.google.com/drive/folde...LyEjYAMLCfZyR8 I have been considering another project and I wanted to refresh my memory on how to implement that. I opened the ePub and got this error message: "Warning: The OPF contains missing or unrecognized media types. Temporaty media types have been generated. You should edit your OPF to fix these." I opened up the file "content.opf" but I have no clue what needs to be "fixed". I copied the file to the above google drive folder. Any suggestion on what the problem(s) might be? I do not recall ever seeing this error before when opening the ePub. Thanks, WV-Mike |
![]() |
![]() |
![]() |
#2 |
Sigil Developer
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 8,758
Karma: 5706256
Join Date: Nov 2009
Device: many
|
I took a look at your opf but did not see any media-types missing or incorrect. So unless there is a non-obvious typo in them, I did not see a problem.
But if you use the latest Sigil and hit the details button on the warning message dialog when it comes up and copy exactly what it says (or screencap it) and post it here. That will tell you everything you need to know on what to fix in the opf. The newer version of Sigil will tell you which file, what the wrong media type was, and what it chose to use instead. But as I said, I could not see any obvious error when I opened your OPF. I do not have access to Sigil to test it and report back as I am travelling today. Could you have added an unmanifested file to your epub somehow? --- Update: dug out my old laptop and fired up your linked epub, and there were *no* warnings at all when opening it with Sigil-2.5.2 So I have no idea why you are seeing any warnings at all when editing that epub in Sigil. Last edited by KevinH; Yesterday at 09:50 AM. |
![]() |
![]() |
Advert | |
|
![]() |
#3 |
Evangelist
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 450
Karma: 3886916
Join Date: May 2013
Location: Ontario, Canada
Device: Kindle KB, Oasis, Pop_Os!, Kobo Forma
|
I tried your epub in both 2.5.2 and a recent 2.6.0 beta appimage. It shows no errors on opening, and no errors with F7 or running epubcheck. Is the one you posted the one where "Temporaty media types have been generated."?
Last edited by retiredbiker; Yesterday at 09:53 AM. |
![]() |
![]() |
![]() |
#4 |
Connoisseur
![]() Posts: 74
Karma: 10
Join Date: Jul 2023
Device: None
|
Thanks,
Here are the details of the error and then the lines from the content.opf file Misc/index.php 'text/x-php' -> 'text/x-php' Misc/w1navigation.php 'text/x-php' -> 'text/x-php' === <item id="index.php" href="Misc/index.php" media-type="text/x-php"/> <item id="index.txt" href="Misc/index.txt" media-type="text/plain"/> <item id="w1navigation.php" href="Misc/w1navigation.php" media-type="text/x-php"/> I removed the above entries and restarted and got this error: Warning: Files are listed in the epub that are not listed in the manifest, they will be ingnored. OEBPS/Misc/index.txt OEBPS/Misc/w1navigation.php OEBPS/Misc/index.php I could not find the above three files. WV-Mike |
![]() |
![]() |
![]() |
#5 |
Sigil Developer
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 8,758
Karma: 5706256
Join Date: Nov 2009
Device: many
|
Ah, I took a look at the standalone content.opf and it has had junk inserted into it by something:
Code:
<item id="index.php" href="Misc/index.php" media-type="text/x-php"/> <item id="index.txt" href="Misc/index.txt" media-type="text/plain"/> <item id="part_2_1974.txt" href="Misc/part_2_1974.txt" media-type="text/plain"/> <item id="w1navigation.php" href="Misc/w1navigation.php" media-type="text/x-php"/> Epub does not support php files. They are scripts that no epub supports. But something you used to read or edit the epub with probably injected. Throw out that separate content.opf. Use the .epub file you actually posted. Start fresh with it. Last edited by KevinH; Yesterday at 10:02 AM. |
![]() |
![]() |
Advert | |
|
![]() |
#6 | |
Connoisseur
![]() Posts: 74
Karma: 10
Join Date: Jul 2023
Device: None
|
Quote:
It is a copy I had locally. I downloaded the file from Gdrive, opened it and got no errors. I am not sure why the local copy on my hard disk is different, but it must but, and thus the errors. Thanks, WV-Mike |
|
![]() |
![]() |
![]() |
#7 | |
Connoisseur
![]() Posts: 74
Karma: 10
Join Date: Jul 2023
Device: None
|
Quote:
WV-Mike |
|
![]() |
![]() |
![]() |
#8 |
Sigil Developer
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 8,758
Karma: 5706256
Join Date: Nov 2009
Device: many
|
We cross posted. Yes removing those lines and the index.txt file and removing any files by those names inside the epub, is the right direction. Or just use the .epub file you posted to start new.
It almost looks like a virus or some computer based php indexing program is injecting these files into the temporary folder used by Sigil. Maybe a whole computer indexing program, or a bad anti-virus program, or a virus itself. If so, you should find what program generates those files and shut it down asap. |
![]() |
![]() |
![]() |
Tags |
opf |
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
Unrecognized media type | lwalper | Sigil | 3 | 03-03-2023 09:30 AM |
OPF missing opf metadata tag | AlanHK | ePub | 1 | 07-25-2017 11:17 AM |
Content.opf media-type | ProDigit | ePub | 2 | 12-18-2015 06:41 AM |
TWO OPF files or something like Media Queries in the OPF file for KF8 and MOBI? | DHahn | Kindle Formats | 3 | 04-17-2012 04:06 AM |
OPF file OPS/package.opf is missing | Run2Eat | ePub | 2 | 05-31-2011 06:52 PM |