Pugpig uses the OPDS catalog specification to access the HTML content.
When creating a Pugpig project you will need to point it to your content on a server, the file you point it to is the edition XML feed. This will list all the editions you want to be seen in your app. By adding entries to this feed you can make new editions available within the app.
Edition XML feed
Each entry points to the atom feed of one edition, the cover that will show in the edition selector and the title of the edition that is displayed under the cover. Here is a brief summary of the rest of the fields. You can see more detailed information here;
- Title - This shows under the cover in the edition selector
- Summary - This is the summary of the particular edition and can be displayed in the edition selector if required. More info.
- ID - it is essential that these are all unique as they differentiate the editions from each other. This should never change once published. Currently this needs to match the iTunes Connect edition In App ID if using In App purchases.
- Updated and Issued dates - These dates enable the ordering of the editions. By default the newest edition shows up on the right hand side of the edition selector - this can be altered if desired.
- Cover image URL - should point to your cover image. This should be 300 - 400px wide and have 4:3 aspect ratio. Supported image types - png, jpeg, jpg or gif.
- Link to the atom feed - The atom feed is specific for each edition and points to all the HTML content within the edition. There are different requirements depending on whether the edition is free or not. See more detail here
- Author - The author of this item. Required unless the top level feed has an author.
Single edition atom feed
Each edition is structured by Pugpig according to the atom feed. It lists the HTML files in the order that they should appear, the relevant HTML5 cache manifest file, the title that will show in your table of contents and the category it should appear under. It also has a “bookmark” link which is used in the share functionality in Pugpig.
- Title - Title of the article, this appears in the Table of Contents within Pugpig
- ID - This needs to be unique for each article. Should be a unique ID appended to the edition ID.
- Updated date - Time when this article was last significant updated. Used internally for caching.
- Published date - Time when this article was first published. Exposed for display but not used internally.
- Summary - Can be used in navigation, not used in default Pugpig
- Category/section - The name of the section in which the entry appears, for example “Latest News”.
- Link alternate - A link to the HTML page that contains the contents of this page.
- Link related - A link to the HTML5 manifest containing all of the assets needed to render this page. Required if not packaging the edition using zip format or HTML manifest referenced inside HTML document. More info here.
- Link bookmark - Sharing link for article. More info Sharing