Skip Navigation

[Resolved] different galleries but alle images are shown

This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.

Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.

Sun Mon Tue Wed Thu Fri Sat
- 10:00 – 13:00 10:00 – 13:00 10:00 – 13:00 10:00 – 13:00 10:00 – 13:00 -
- 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 -

Supporter timezone: Asia/Kolkata (GMT+05:30)

This topic contains 2 replies, has 2 voices.

Last updated by Minesh 9 months ago.

Assisted by: Minesh.

Author
Posts
#2689826

Dear Support Team,

I've encountered a challenge on our website's apartment listings page, specifically at: hidden link.

Issue Description:
Each apartment listing features a photo gallery. However, when viewing an image within a gallery and navigating through the images, the gallery includes photos from all apartments, not just the one I'm interested in.

Desired Outcome:
I would like the gallery for each apartment to only display images from that specific apartment. This way, when a user clicks on an image in a gallery, they can only navigate through photos belonging to that particular apartment.

Could you please advise on how to implement this functionality? Your assistance would greatly streamline our website's user experience.

Many thanks in advance for your support.

Best regards,
Matthias

#2689858

Minesh
Supporter

Languages: English (English )

Timezone: Asia/Kolkata (GMT+05:30)

Hello. Thank you for contacting the Toolset support.

Can you please share details how exactly you are displaying those image galleries?

Maybe you can share admin access details that will help us to quickly review your setup.

*** Please make a FULL BACKUP of your database and website.***
I would also eventually need to request temporary access (WP-Admin and FTP) to your site. Preferably to a test site where the problem has been replicated if possible in order to be of better help and check if some configurations might need to be changed.

I have set the next reply to private which means only you and I have access to it.

#2690717

Minesh
Supporter

Languages: English (English )

Timezone: Asia/Kolkata (GMT+05:30)

This is a known issue to us and already been reported but there is no ETA when the official fix made available.

However - the good news is that we have workaround that will fix the issue.

Can you please check now: hidden link

I've added the following custom JS code to your View block's Custom JS section:
- hidden link

jQuery(document).ready(function($){
   
  $("div.tb-gallery").each(function(topindex){
   $(this).find("a").each(function(index){
    $(this).attr("data-lightbox","lightbox-"+topindex);
   });
   
  });
 
});

More info:
- https://toolset.com/course-lesson/adding-custom-javascript-to-views-templates-and-archives/#steps-for-adding-javascript-to-a-view