what is the best solution to display pdf on iphone?

Page: 1

Author Post
Member
Registered: Apr 2013
Posts: 8
I all,
it seems that floatbox can display (sort of) pdf in a ...floatbox.
I'm trying it on iphone in my web app created using JQuery Mobile 1.3.1.
It almost works: the floatbox opens but then the result are not predictable: sometimes the pdf is shown, sometimes it takes too long to display (it's a 2MB pdf).
But once the pdf is shown in floatbox it seems that I can't do nothing with it.
I cannot browse pages. Is this right?
Or does it depends on the apps installed to handle pdf file on the iphone?
On a desktop browser it works perfectly.
TIA

tony
Administrator
Registered: Aug 2008
Posts: 3382
By default, in current versions, unless directed otherwise through option settings, Floatbox will send pdf documents to a new window on iPhones and other small-screen devices. This usually works out quite well as most devices have native pdf viewers available.

Publishing a pdf document on scribd.com and opening it from there is a pretty good cross-browser approach. Floatbox has some specific support for scribd content in it, and there's some write-up in the instructions about this.

The behaviour you describe is not familiar to me and I won't speculate about it in the absence of -- you guessed it -- a page where it can be seen in context.
Member
Registered: Apr 2013
Posts: 8
Hi, Admin,
thanks for your reply.
Here a sample: http://ww7.nardi.info/mobi2

This web app should be added to iphone home for better viewing experience, but it's optional.

Once opened on the iphone, just click the "Libretto di istruzioni (floatbox)" link.
It opens a floatbox with the sample.pdf but you can't browse all pages.

TIA ;)

tony
Administrator
Registered: Aug 2008
Posts: 3382
Thanks for the link Tony.

You have mobileNewWindow:false set in your fbPageOptions (which, by the way, is defined 3 times on that page). This setting prevents Floatbox from showing the pdf document in a new window on mobile devices, which is how it prefers to display pdf and other documents. This is scrollable content on a device that does not have scrollbars. On such devices, there is usually an awkward two-finger scroll available but it doesn't work very well, many users don't know about it, and there's no visual clue that the content is scrollable. The two-fingered scroll doesn't appear to work at all on a pdf document.

Strongly recommend you remove that mobileNewWindow:false setting and let the default behaviour of opening pdf documents in a new window occur.

Page: 1