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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 10, 20262026-06-10T12:54:29+00:00 2026-06-10T12:54:29+00:00

GOAL: Create element which will display current big image and few thumbnails. When somebody

  • 0

GOAL:
Create element which will display current big image and few thumbnails. When somebody click on thumbnail, current big image needs to be replaced with clicked one. Shadowbox should work only on big image. If there are few images (thumbnails) shadowbox must contain all three big images (not to display only one).

ISSUES:
While code bellow work, it still have some issues to be fixed.

  1. On first load, when I click on thumbnail, main big image in #panel is firstly replaced with thumbnail, and then after ~1 second is replaced with normal big one. So big image should be first preloaded on click and then appended to #panel or something similar.
  2. rel attribute is somehow lost in replacing. When there is a new image appended to #panel it looks like it loose rel attribute (shadowbox not work)
  3. Clicking on thumbnails load shadowbox which should be prevented. Shadowbox should be loaded only when there is a click on big image in #panel. When somebody click on that big image shadowbox should load all big images. This may be tricky and may require changed html code.

WORKING DEMO
Demo no longer work

HTML:

<div id="panel">
  <a href="path_to_image1.jpg" rel="shadowbox[page]">
   <img src="scripts/timthumb.php?src=path_to_image1.jpg&w=200&h=20" alt="Image name1" />
  </a>
</div>

<div id="thumbs">
  <a href="path_to_image1.jpg" rel="shadowbox[page]">
   <img src="scripts/timthumb.php?src=path_to_image1.jpg&w=30&h=30" alt="Image name1" />
  </a>
  <a href="path_to_image2.jpg" rel="shadowbox[page]">
   <img src="scripts/timthumb.php?src=path_to_image2.jpg&w=30&h=30" alt="Image name2" />
  </a>
  <a href="path_to_image3.jpg" rel="shadowbox[page]">
   <img src="scripts/timthumb.php?src=path_to_image3.jpg&w=30&h=30" alt="Image name3" />
  </a>
</div>

JS:

$('#thumbs a').click(function(evt) {
  evt.preventDefault();
  var clickedElement = $(this).clone().find('img').attr('src', function(i, src){
    return src.replace('w=30&h=30', 'w=200&h=200')
  }).end();
  $('#panel').html(clickedElement);
});
  • 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-06-10T12:54:30+00:00Added an answer on June 10, 2026 at 12:54 pm

    I found http://slidesjs.com/ which have exactly the same functionality which i wanted to achieve. I would like to thank everyone who tried to help me.

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

Sidebar

Related Questions

My goal is to create an entry form (addnew.php) that will allow me to
The goal is to create a mock class which behaves like a db resultset.
I have a container element in which I create on the fly/place() a form,
Goal: I want to get the text from the selected element and then create
I'm attempting to create a simple column view which will allow me to explore
Goal: to create a percentage column based off the values of calculated columns. Here's
Duplicate: PHP validation/regex for URL My goal is create a PHP regex for website
I am very new to Json and my goal to create the Json output
My goal is to create a canned email on my server and then send
My goal is to create a list from menu.bin. This is the func: pitem

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.