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 7162691
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 28, 20262026-05-28T13:46:36+00:00 2026-05-28T13:46:36+00:00

I have a gallery type of interface that I’m trying to get to work,

  • 0

I have a gallery type of interface that I’m trying to get to work, I want to be able to click outside of it to close it, however there is a div inside that contains the main elements, photos, and things to click. However as it is now when you click inside the div it closes, because it’s a child in the element that when you click it closes.

I have the divs like this:

 <div class="theater-wrapper">
     <div class="theater-container"></div>
 </div>

everything is loaded into theater-container via ajax.
When you click .theater-wrapper it should fire the event to close, however when you click theater-container it shouldn’t.

This is how I have tried to close it:

$(".theater-wrapper").click(function (event) {
     $('.theater-wrapper').hide(); 
event.stopPropagation();

  });

I have a jsfiddle showing this in action: http://jsfiddle.net/Cs8Kq/1/

  • 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-05-28T13:46:37+00:00Added an answer on May 28, 2026 at 1:46 pm

    If you want to stop propagation of the click event on .theater-container, then that’s where you need to put the command. Right now you have it applied to the .theater-wrapper click action.

    $(".theater-container").click(function (ev) {
        ev.stopPropagation();
    });
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have photo gallery code that does image re-sizing and thumbnail creation. I use
I have custom gallery. Gallery represents items that are frame layout. There are one
I have a gallery that's loaded via a BaseAdapter . This works fine. I
I have an image gallery that I created by reading the contents inside a
I have a photo gallery I would like that every time a user does
I have a simple form that generates a new photo gallery, sending the title
Right now I have a image gallery that changes images when a user clicking
So I have this webpage built that has a photo gallery on the left
I have a search field, and using that single text box I want the
I have an images table with a column called type . I simply want

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.