Skip Navigation

[Resolved] Sorting repeater gallery field based on order in single page

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.

No supporters are available to work today on Toolset forum. Feel free to create tickets and we will handle it as soon as we are online. Thank you for your understanding.

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 8 months, 2 weeks ago.

Assisted by: Minesh.

Author
Posts
#2686996
Screenshot 2024-03-08 182221.jpg
Screenshot 2024-03-08 182056.jpg
Screenshot 2024-03-08 181938.jpg

I built this site back in 2020, and am doing some updates for the client.

I'm trying to make it so the images in this repeater field can be sorted using the drag and drop functionality.

I thought I would just need to sort it by "Menu Order" or by "Field - Gallery Image" or by "field-toolset-post-sort-order" but neither of those is working. I've tried doing it "As a native custom field" and by "String" and "Number" but none of those are working.

Is there any documentation that you are following?

Not that I have found.

What is the link to your site?

hidden link

You will notice in the images that the three images from the Gallery Item images does not match what is showing up on the page. The first image in file 182221.jpg is the featured image, and is where it is supposed to be. The next three images should be in the same order as the ones in screenshot 182056.jpg.

#2687200

Minesh
Supporter

Languages: English (English )

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

Hello. Thank you for contacting the Toolset support.

I would like to know - are those repeating field group images added from frontend using Toolset form or backend?

*** 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.

#2687209

Minesh
Supporter

Languages: English (English )

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

I see with the view you are using:
- hidden link

You have added the following li code outside the view's loop:

<li data-thumb="[wpv-post-featured-image size='custom' width='400' height='225' crop='true' output='url']">
          [wpv-post-featured-image size="custom" width="1500" height="1000" crop="true"]
        </li>

That means you have added the above featured image that will be always displayed as the first image.

I can se the other images are displayed with correct order.

The ordering is set as you can see with the following screenshot:
- hidden link

#2687216

Okay, it looks like the only thing I had off is I was doing it "Ascending - > As a native custom field" instead of "Ascending -> As a number"

I thought I had tested each of those options, but I must have gotten mixed up with refreshing over and over again, or something like that.

Well, that's what I was hoping for, a quick easy fix! Thank you so much for your help, and for this great plugin.