I have a login box that slides/toggles up and down when an <a>
link is clicked.
This is a DIV that is around 150px by 100px is size.
When someone clicks outside this DIV I want the DIV to slide backup. I've been playing with focusout() but I must have the wrong function.
Any advice? code below.
$('a#member_login').click(function(event) {
event.preventDefault();
$('div#member_login_container').slideToggle();
});
// Hide Login Box if Click outside the Login Box
$('div#member_login_container').focusout(function(event) {
alert('here');
//$('div#member_login_container').slideUp();
});