Skip Navigation

[Gelöst] view result not outlining as expected

This support ticket is created vor 7 Jahren, 3 Monaten. 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.

Heute stehen keine Supporter zur Arbeit im Werkzeugsatz-Forum zur Verfügung. Sie können gern Tickets erstellen, die wir bearbeiten werden, sobald wir online sind. Vielen Dank für Ihr Verständnis.

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)

Dieses Thema enthält 7 Antworten, hat 2 Stimmen.

Zuletzt aktualisiert von filipV-3 vor 7 Jahren, 2 Monaten.

Assistiert von: Minesh.

Author
Artikel
#566016

hi, in a content template i added via add view a code to show a photogallery with lightbox. I actually tried 4 different codes. While the first two are perfectly outlining the thumbnails in the template, there is a problem with showing the image in the lightbox.
The last two codes do perfectly do the lightbox job, but in the template it refuses to outline the thumbnails properly, and adds them 1 below the other.
This is the code that shows good in template but bad in lightbox (the second is via thickbox class but otherwise similar)
[types field='photogallery' width='209' height='209' align='none' resize='crop' separator=' '][/types]

This is the code that shows good lightbox but bad outlining:
[wpv-for-each field="wpcf-photogallery"]
[types field="photogallery" width='209' height='209' align='none' resize='crop' separator=' '][/types]
[/wpv-for-each]

see: ../profile/sandra/ (pls dont publish url) below the map. 2+2 efforts

Any idea why it won't behave as told? 🙂

And when we're on it: would it be possible to show only 3 first thumbnails in content template, but while showing all images (not just 3) when looking in the lightbox? (to not have very long page when there are many pic. Or perhaps a slider or so where's always only 3 pics seen in template, but sliding to the next ones?)

thanks!

#566294

Minesh
Supporter

Sprachen: Englisch (English )

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

Hello. Thank you for contacting the Toolset support.

Well - Using view's you can also build the slider view as per your requirement. You can find more details with the following link:
=> https://toolset.com/documentation/user-guides/creating-sliders-with-types-and-views/

Also, I do not able to see anything with the link you shared. Could you please share exact problem URL with access details and few screenshot with details whats not working and how you would like to display the output exactly.

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

#566750

Minesh
Supporter

Sprachen: Englisch (English )

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

Well - I disabled the plugin responsive lightbox as WordPess itself gives thickbox and I've activated it by adding the following line to your current theme's functions.php file.

add_action( 'wp_enqueue_scripts', 'add_thickbox' );

Now, I've added the code to your text block as given under and it looks good:

[wpv-for-each field='wpcf-photogallery']
<a class="thickbox" href="[types field='photogallery' raw='true'][/types]">[types field="photogallery" size="thumbnail"][/types]</a>
[/wpv-for-each]

Also, if you want image slider, you can use our readymade module. Please check the following link:
=> https://toolset.com/home/module-manager/
[ Click on tab "slider" and download and install the module]

You can download the module-manager addon plugin from the following link:
=> https://toolset.com/download/toolset-module-manager/#changelog

Well - Using view's you can also build the slider view as per your requirement. You can find more details with the following link BUT it needs slides/images to be setup as child posts.
=> https://toolset.com/documentation/user-guides/creating-sliders-with-types-and-views/

#566765

Hi Minesh,
not sure what you mean 'now it looks good'? I see that now and the layout is wrong, and the lightbox as well. The thumbnails are still seen below each other instead of per 3 on a line, as was correct before, and the lightbox doesn't include anymore the previous/next buttons.

Please check, thank you!

#566773

Minesh
Supporter

Sprachen: Englisch (English )

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

Ok - I've changed the code as given under as you want prev and next button with the popup.

[wpv-for-each field='wpcf-photogallery']
<div style="float: left; margin: 1px;"><a class="thickbox" href="[types field='photogallery' raw='true'][/types]" rel="gallery">[types field="photogallery" width='209' height='209' align='none' resize='crop' separator='&nbsp;'][/types]</a></div>
[/wpv-for-each]

It's showing 2 images per row as you can see that there is no enough space to display 3 images per row. To display 3 images per row you need to reduce the image size.

#566779

hi, thanks! I see 3 in a row now, it's probably due to monitor size that you see 2; i'll play with sizes.
I also see the previous/next buttons now, they work. Just that they are a bit un-userfriendly there at the bottom jumping place with each pic. Earlier they were on the image seen at hover. Can this be due to thickbox standard? Would that work if i change that code from thickbox to another lightbox?

And next i'm gonna try that slider again according your extra instructions.

Best regards

#566786

Minesh
Supporter

Sprachen: Englisch (English )

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

Yes - its due to standard Thickbox standard as every pop-up library has its own standard and defaults.

As your original issue is resolved - may I kindly ask you to open a new ticket for each new question. This will help other users searching on the forum.

#566812

Sure, thanks Minesh!