O'Reilly logo

Instant Fancybox by Kyle Diedrick

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Interacting with Fancybox (Advanced)

Fancybox provides a number of methods that we can use to programmatically interact with the Fancybox pop up. Let's take a look at some of these methods and at what they allow us to do.

Getting ready

To make things simple, we are just going to use a single-image pop up like the one found in the Installing Fancybox recipe. We'll be looking at the pieces of the API that allow us to interact with just the Fancybox pop up in this recipe. We'll cover manually opening and closing Fancybox, the update and toggle functions, the reposition function, the show and hide loader functions, and the close function.

How to do it...

  1. Let's start with opening the Fancybox pop up using the API. We used this briefly in the recipe on ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required