I want to use simple popover to display our privacy policy. For reasons beyond my control the client insists that it be a PDF. Okay.
The problem is that the following code only works in Chrome. The latest versions of Firefox and IE11 won't open it properly. (The overlay and loading animation appear but no popup border and PDF. And worse, in IE11 it prompts for download or open.)
Here's the HTML:
<a class="fancybox" href="http://blnwb.co/pdf.pdf">Popup</a>
Here's the JavaScript:
$(document).ready(function () {
$(".fancybox").fancybox({
type: 'iframe'
});
});
JSFiddle: http://jsfiddle.net/LP7bq/
NOTE: I've seen the suggestions to use Google Docs to display the PDF in an iframe. Again that won't fly with the client. They insist on hosting all the .js period. No CDN, etc.
NOTE 2: I've also seen this old answer which also doesn't work in IE11.