Difference between revisions of "ZIM file format"

Jump to navigation Jump to search
901 bytes added ,  11:04, 17 October 2010
Line 224: Line 224:


The URLs in the UrlPointerlist are not encoded. Some readers process the requests that already do the decoding internally whereas most readers will handle the URLs directly. In this case you have to do the decoding before you pass the parameter to zimlib, but zimlib already provides a method to do so.
The URLs in the UrlPointerlist are not encoded. Some readers process the requests that already do the decoding internally whereas most readers will handle the URLs directly. In this case you have to do the decoding before you pass the parameter to zimlib, but zimlib already provides a method to do so.
=== Local Anchors ===
Many articles - especially when a table of contents is used - use local anchors to jump within an article.
<pre>
<a href="/A/foo#headline1">jump to article foo, headline 1</a>
</pre>
The browser handles these local anchors by itself. It will determine if another article has to be loaded (local anchor inside another article than the currently shown) and will send a request only with the article URL without the local anchor - in our example "/A/foo". After the article has been loaded the browser will then search for the local anchor tag and jump to the right location.
If you use a common rendering engine or HTML widget you don't have to care for this cases, you can just use the requests as they are submitted by the engine / widget.
Should you render the article contents by yourself you have to consider this and take care of it before you hand requests to zimlib.

Navigation menu