• Resolved selfagency

    (@selfagency)


    Hi,

    Love the plugin and it works great in Chrome and FF, but in Internet Explorer, it doesn’t work at all, and according to the developer tools, this line is a security problem:

    SCRIPT14: A security problem occurred.

    jQuery(‘a.fancybox-pdf, area.fancybox-pdf, li.fancybox-pdf a:not(li.nofancybox a)’).fancybox( jQuery.extend({}, fb_opts, { ‘type’ : ‘html’, ‘width’ : ‘90%’, ‘height’ : ‘90%’, ‘padding’ : 10, ‘titleShow’ : false, ‘titlePosition’ : ‘float’, ‘titleFromAlt’ : true, ‘autoDimensions’ : false, ‘scrolling’ : ‘no’, ‘onStart’ : function(selectedArray, selectedIndex, selectedOpts) { selectedOpts.content = ‘<embed src=”‘ + selectedArray[selectedIndex].href + ‘#toolbar=1&navpanes=0&nameddest=self&page=1&view=FitH,0&zoom=80,0,0″ type=”application/pdf” height=”100%” width=”100%” />’ } }) );

    https://wordpress.org/plugins/easy-fancybox/

Viewing 8 replies - 1 through 8 (of 8 total)
  • Hi selfagency,

    Issues in IE are usually related to a missing or incorrect DOCTYPE declaration. Also make sure the doctype is declared absolutely first. Not even a blank line or spaces should come before it.

    If you can share a link to the page in question, I might be able to tell you more…

    Thread Starter selfagency

    (@selfagency)

    My site is empirebrew.com.

    Here’s the header, which has no space at the beginning.

    <!DOCTYPE html>
    <!–[if IE 7 ]> <html dir=”ltr” lang=”en-US” class=”no-js ie7 oldie”> <![endif]–>
    <!–[if IE 8 ]> <html dir=”ltr” lang=”en-US” class=”no-js ie8 oldie”> <![endif]–>
    <!–[if (gte IE 9)|(gt IEMobile 7)|!(IEMobile)|!(IE)]><!–><html dir=”ltr” xmlns=”http://www.w3.org/1999/xhtml&#8221; lang=”en-US” prefix=”og: http://ogp.me/ns# fb: http://ogp.me/ns/fb#&#8221; class=”no-js”><!–<![endif]–>

    Please note there is a blank line above the doctype declaration. It might be there in your themes header.php but it might also be coming from a modified wo-config.php or a plugin…

    Funny thing: that that blank line is only visible in the home page source. Not other pages.

    Anyway, if I look at a page like http://empirebrew.com/gallery/120walton then it’s not FancyBox but prettyPhoto that is handeling the mightbox effect. You cannot use two lightboxes together and expect no problems…

    Thread Starter selfagency

    (@selfagency)

    Dunno why there are two lightboxes and will look into that – but the page that I’m having issues with is a private page and all the links are PDFs. Pretty Photo doesn’t work on PDFs. When I click the links in IE, nothing happens.

    PrettyPhoto is part of your theme. I’d advise to stick with prettyPhoto and use the method on http://www.kriesi.at/support/topic/how-to-use-iframes-with-prettyphoto/ to link to your PDF files.

    FancyBox does not ‘display’ PDF files. It can embed them but will always depend on visitor browser plugin to display them. Going with the iframe method + prettyPhoto will have this result: browsers with plugin will display the PDF, browsers without it will ask the user to download it…

    Thread Starter selfagency

    (@selfagency)

    Not that troubleshooting PrettyPhoto is your problem, but that resolution doesn’t work at all.

    I’d rather disable PrettyPhoto all together and use FancyBox.

    Then you’ll have to look for any theme option to disable prettyPhoto and if there is none, hack the theme to not include the script and style related files anymore…

    Going back to the initial security problem message, it looks like IE is blocking the dynamically inserted embed code. The only thing to do (apart from changing the security restriction settings in IE) is to switch to the iFrame method for FancyBox:

    Go to Settings > Media and disable the PDF option and enable the iFrame option. Then edit the PDF links in your posts/pages to include class="fancybox-iframe"

    Please note that this is similar to making prettyPhoto use iframe embeds.

Viewing 8 replies - 1 through 8 (of 8 total)
  • The topic ‘Internet Explorer security problem’ is closed to new replies.