I just installed a slideDown panel from the "FAST QUOTE" button on the top of the page:
Is it possible to make the panel slideUp when the user clicks anywhere outside of the slideDown panel? Below the Panel?
I just installed a slideDown panel from the "FAST QUOTE" button on the top of the page:
Is it possible to make the panel slideUp when the user clicks anywhere outside of the slideDown panel? Below the Panel?
It seems you are using jQuery (Saw from jQuerify (Firebug)). So you need to trigger the close button click when you click in the outside area.
Assuming the slide events are on .closeQ
, specify your outsidearea and bind the click
event to trigger the close button.
$("outsidearea").click(function(){ $(".closeQ").trigger("click"); });
Answering your comment:
On your slide down/up method add this code (at the first line (close first, open after))
$(".btn-slide.closeQ, .btn-slide2.closeQ").trigger("click");
It will find if the panel is open, and if it is opened it will trigger the event to close.