WordPress.org

Ready to get started?Download WordPress

Forums

Easy FancyBox
Is there a way to set the default zoom on pdfs in Easy Fancybox? (2 posts)

  1. ontargetpro
    Member
    Posted 3 years ago #

    I attempted saving the .pdfs with initial zoom of 50% and it works great from my browser http://gourmetexas.com/pdfs/test50.pdf . In Easy Fancybox it starts to open that way, but then goes back up to 134 percent. Any way to override this? Thanks!

  2. RavanH
    Member
    Plugin Author

    Posted 3 years ago #

    Hi,

    It all depends on the browser plugin the visitor is using. In Google Chrome for example, I do not get 50% zoom when I open the pdf straight in a browser tab so I guess there is no solution for that case. But if you want it to work 'at least' for anyone using the plugin provided by Adobe then continue reading...

    Easy FancyBox uses an embed code that tries to be as cross-browser compliant as possible. This code tries to pass some parameters to the plugin which seem to be picked up by Adobe's plugin but not others. These parameters are:

    toolbar=1&navpanes=0&nameddest=self&page=1&view=FitH,0&zoom=80,0,0

    You can find them (twice! do Ctrl+F and search for zoom=80) inside easy-fancybox-settings.php and if you change the parameter zoom=80,0,0 to zoom=50,0,0 you should get a 50% zoom level by default. Or you can try removing the &zoom=50,0,0 all together and see if that defaults to your saved zoom level.

    You'll have to test a bit and make sure you change both (!) the instances of the string to the same parameters or you will get different results on different browsers.

    If you find it all too complicated, contact me on http://4visions.nl/en/contact/ to discuss a custom version of Easy FancyBox with all your preferred settings.

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic