Preface: I'm an ePub/HTML novice. That said…
I exported a file, with pictures, from Pages to ePub. Everything worked, including the automatic TOC. Oddly, the OPF file did not list the pics by their actual_filename, but like this:
<item id="dataItem3" href="images/1___$!@%25!___pastedGraphic.png" media-type="image/png" />
As, for one thing, the files weren't PNG but JPG, I "corrected" these links, giving the target it's actual filename, such as:
<item id="dataItem3" href="images/000870.jpg" media-type="image/jpg" />
But when I exported it again to iBooks, the automatic TOC had disappeared. Though the file seemed to work: it had all the pictures, including a video.
FYI, the NCX and OPF files both validated at:
http://www.w3schools.com/xml/xml_validator.asp
Many questions came to mind, the most obvious were:
1. Am I supposed to be able to edit the OPF Manifest section. (Otherwise, how would I add pics to a file?)
2. If both OPF and NCX files validate, what might I be doing wrong?
Thanks for the guidance.