Skip Navigation

[Resolved] Links for multiple values fields

This support ticket is created 2 years, 8 months ago. There's a good chance that you are reading advice that it now obsolete.

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 3 replies, has 2 voices.

Last updated by luisP-6 2 years, 8 months ago.

Assisted by: Minesh.

Author
Posts
#2321239

Hi,

How could I link elements for multiple value fields separated by comma? For example, this code shows all images:

[types field='imagegallery' separator=', '][/types]

Then, how could I link every image to the correct thumbnail?

I only can fix it using index parameter, but then it is limitating number of images. For example:

[types field='imagegallery' separator=', ' index='1'][/types]
[types field='imagegallery' separator=', ' index='2'][/types]
etc .

Thank you!

#2321269

I solved this problem with the gallery using this tip:

https://toolset.com/forums/topic/wp-for-each-for-image-gallery-returning-all-url-not-each/

But I have same doubt for other fields. For example, I have 2 multiple value fields separated by comma:

- Link
- Link title

I want to do this, but without using "index". Is there any way to link every title to the link?

[types field='link_title' separator=', ' index='1'][/types]

#2322491

Minesh
Supporter

Languages: English (English )

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

No, either you should go with [wpv-for-each] or there is another way that you should create a repeating field group where the repeating field group will hold the link and link title fields.

Here is the info how you can create repeating field group:
- https://toolset.com/course-lesson/creating-and-displaying-repeatable-field-groups/#creating-repeatable-field-groups

Here is the info about how you can display the repeating field group:
- https://toolset.com/course-lesson/creating-and-displaying-repeatable-field-groups/#displaying-repeatable-field-groups

#2325745

My issue is resolved now. Thank you!