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

  • Home
  • SEARCH
  • 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 7128551
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 28, 20262026-05-28T11:09:01+00:00 2026-05-28T11:09:01+00:00

http://www.leandrovieira.com/projects/jquery/lightbox/ sample so i have get images in while loop here is my code

  • 0

http://www.leandrovieira.com/projects/jquery/lightbox/ sample


so i have get images in while loop here is my code

<td id="gallery">

<a href='<?=$path ?>'>
 <img width="50" height="50" src=<?php echo $path; ?> />
 </a>

</td>


 $(function() {
            $('#gallery a').lightBox();
        });
    </script>

when i click first image light box effect works fine but when i click second image light box effect does n’t work please guide me

Thanks for Advance

  • 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-28T11:09:02+00:00Added an answer on May 28, 2026 at 11:09 am

    The problem is you have multiple <td id="gallery". You shouldn’t use the same id for multiple elements, because $(‘#gallery’) would always return the first one, but also because it’s wrong!

    Either move it into the table: <table id="gallery",

    or change it to class: <td class="gallery" and change the query: $('.gallery a').lightBox();

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

Sidebar

Related Questions

http://www.security.org.sg/code/loadexe.html http://pastebin.com/QFHASx75 I've compiled this but can't get it to work properly, It runs
http://www.ericmmartin.com/projects/simplemodal/ There's two examples near the bottom of the page that show how to
http://www.example.com/http://www.test.com I have tried many different methods using .htaccess with no luck. I need
http://www.keironlowe.host56.com/Website%20Testing/index.html At the bottom below the paragraph of text I have two images with
http://www.queness.com/post/328/a-simple-ajax-driven-website-with-jqueryphp I'm trying to get the above script to work, but with some changes.
http://www.thecommonwealthmembers.com/ I designed a website, and used jQuery and CSS on the contact form
http://www.myserver.com/exile?Key1=Value1&Key2=Value2 When i get a request in this format to my server, how do
http://www.dennys.com I'm wondering how the top navigation was programmed, From the source code I
http://www.malsup.com/jquery/corner/ Is there any real disadvantage (like SEO) to creating the rounded corners pixel
http://www.e-fluential.com/offline/ Screen grab: I can't get the div that the blue words blah blah

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.