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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 26, 20262026-05-26T21:32:12+00:00 2026-05-26T21:32:12+00:00

I want by clicking the image(represented by the cross box), a rectangle area will

  • 0

I want by clicking the image(represented by the cross box), a rectangle area will be expanded downward to display information(kind of toggle). How can I do that. Thanks.

when I click another image, I also want the first rectangle area will retract and the next will expand(i.e. only one rectangle area a time)

I want the similar effect here: themetrust.com/demos/reveal/#footloose , but what I really want is that the grey area to put under each row of the photos and probably expecting ajax and rails implementation.

The mock up

  • 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-26T21:32:13+00:00Added an answer on May 26, 2026 at 9:32 pm

    You haven’t given much information, but one strategy you could use is to associate each clickable img with a container that will show or hide:

    <div id="images">
        <img src="img_src" data-target="#content1" />
        <img src="img_src" data-target="#content2" />
        <img src="imgs_src" data-target="#content3" />
    </div>
    <div id="contents">
        <div id="content1" class="active">Content1</div>
        <div id="content2">Content2</div>
        <div id="content3">Content3</div>
    </div>
    

    Then you could wire up an event handler for each image, retrieve the content and show it:

    $("#images img").on("click", function () {
        var content = $(this).data("target");
        $("#contents .active").hide("slow", function () {
            $(this).removeClass("active");
            $(content).show("slow", function () {
                $(this).addClass("active");
            });
        });
    });
    

    Also toggling an active class along the way.

    Example: http://jsfiddle.net/k8zCU/

    You might want to check out the following documentation for more effects you could use:

    • show
    • fadeIn
    • slideUp
    • animate
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have an image on clicking it deletes a user ,i want to display
I want to show a custom image with some data in it while clicking
I want to display the mail ID in my view such that clicking the
I want to insert smiley code in text area under cursor position by clicking
I want to change the checked radio btn by clicking on an image who
I've got this idea. In a webpage design, after clicking an image i want
In my gsp page, after clicking on an image, i want to save something
I want to display the Request for Permission box directly when the user enters
I have three images that I want to cycle through when clicking on a
I have a .NET application running on windows. I want clicking on some page

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.