Title: Call Fancybox from php?
Last modified: August 30, 2016

---

# Call Fancybox from php?

 *  [jc.a](https://wordpress.org/support/users/jca-1/)
 * (@jca-1)
 * [10 years, 10 months ago](https://wordpress.org/support/topic/call-fancybox-from-php/)
 * is it possible to call fancybox from php? I have some conditions on the on my
   functions.php. also if possible not just to trigger click, but actually calling
   the box?
 * [https://wordpress.org/plugins/easy-fancybox/](https://wordpress.org/plugins/easy-fancybox/)

Viewing 2 replies - 1 through 2 (of 2 total)

 *  [Rolf Allard van Hagen](https://wordpress.org/support/users/ravanh/)
 * (@ravanh)
 * [10 years, 10 months ago](https://wordpress.org/support/topic/call-fancybox-from-php/#post-6278091)
 * Hi JC, what do you mean with ‘call’ here? Do you wish to control on which pages
   the lightbox script files are included?
 * > also if possible not just to trigger click, but actually calling the box?
 * Yes it should be possible. See [http://fancybox.net/blog](http://fancybox.net/blog)
   under “6. Start FancyBox on page load” there is a manual call example. But if
   you’re already going in that deep, you should consider building FancyBox into
   your theme yourself instead of using a plugin like Easy FancyBox.
 *  Thread Starter [jc.a](https://wordpress.org/support/users/jca-1/)
 * (@jca-1)
 * [10 years, 10 months ago](https://wordpress.org/support/topic/call-fancybox-from-php/#post-6278122)
 * Hello sir RavanH, what i mean by ‘call’ is invoking it or a php function to execute
   to show a specific fancybox-hidden div instead of clicking the link with the 
   fancybox-inline class.
 * before this, i used to do jquery to trigger a click. but my conditions are on
   the server-side using php, so i was thinking of how can i trigger sa fancybox
   to show up using php.
 * I’ll check out the blog! thank you! 🙂

Viewing 2 replies - 1 through 2 (of 2 total)

The topic ‘Call Fancybox from php?’ is closed to new replies.

 * ![](https://ps.w.org/easy-fancybox/assets/icon-256x256.png?rev=3188201)
 * [Firelight Lightbox](https://wordpress.org/plugins/easy-fancybox/)
 * [Support Threads](https://wordpress.org/support/plugin/easy-fancybox/)
 * [Active Topics](https://wordpress.org/support/plugin/easy-fancybox/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/easy-fancybox/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/easy-fancybox/reviews/)

## Tags

 * [php](https://wordpress.org/support/topic-tag/php/)

 * 2 replies
 * 2 participants
 * Last reply from: [jc.a](https://wordpress.org/support/users/jca-1/)
 * Last activity: [10 years, 10 months ago](https://wordpress.org/support/topic/call-fancybox-from-php/#post-6278122)
 * Status: not resolved