Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8857399
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 14, 20262026-06-14T14:34:49+00:00 2026-06-14T14:34:49+00:00

I use fancybox to open a popup window with a form. At the moment

  • 0

I use fancybox to open a popup window with a form. At the moment popup comes to life when mouse leaves main page. In order to make this work i have a hidden link tag which i simulate with trigger() function that is clicked in order that link’s href which is forms id with fancybox to come in life. Code as follows:

<a id="trigger" href="#feedback_form" style="display:none"></a>


$(document).mouseleave(function() {

//Triggers popup
$("#trigger").fancybox().trigger('click'); 

     //Popup function
     $("#trigger").fancybox({

     });

 });

Is there any other way to do this?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-14T14:34:50+00:00Added an answer on June 14, 2026 at 2:34 pm

    Option 1 : hidden link and two functions :

    1.1 Bind fancybox to selector :

    $("#trigger").fancybox();
    

    1.2 Then trigger the selector :

    $("#trigger").trigger('click'); 
    

    Option 2 : hidden link and a single function :

    $(document).mouseleave(function() {
        $("#trigger").fancybox().trigger('click');
    });​
    

    See : JSFIDDLE

    Option 3 (recommended): NO hidden link and a single function :

    $(document).mouseleave(function() {
        $.fancybox("#feedback_form");
    });​
    

    See : JSFIDDLE

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I use fancybox to show a popup window from another url, using iframe. Here
I need help! I use fancybox and use iframe to show other page but
I am using fancybox to open submitted form like this: <form name=form id=myForm action={$smarty.server.PHP_SELF}?action=abc
I'm trying to use Fancybox to expand an inline element on a page to
I have a page where I need to use 2 different FancyBox styles for
I'm using Fancybox ( http://fancybox.net ) to pop open an iFrame. In order to
I would like to use jQuery Fancybox or Lightbox to load a contact form
I Use Fancybox to display complex forms on an intranet site. The page the
I use Fancybox and Scrolling Carousel . Try to make : click $(.subject) into
I want to use fancybox to popup a message if a certain button is

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.