Navigation überspringen

[Gelöst] Hiding navigation arrows on slideshow

This support ticket is created vor 1 week, 1 day. 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 -

Zeitzone des Unterstützers: Asia/Kolkata (GMT+05:30)

Dieses Thema enthält 15 Antworten, hat 1 Stimme.

Zuletzt aktualisiert von shannonM-4 vor 4 days, 3 hours.

Assistiert von: Minesh.

Author
Artikel
#2865667

Minesh
Unterstützer

Sprachen: Englisch (English )

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

I've created the following code snippet and added the "Code Snippet" plugin:
- versteckter Link

function toolset_homepage_slideshow_count_shortcode() {
	global $post;

	if ( ! $post instanceof WP_Post ) {
		return 0;
	}
	
	

	$values = get_post_meta(
		$post->ID,
		'wpcf-homepage-slideshow',
		false // Return all values for the repeating field.
	);
	

	return   count( $values);
}
add_shortcode('toolset_homepage_slideshow_count','toolset_homepage_slideshow_count_shortcode');

The above shortcode will return the total number of images you uploaded for the repeating field and then I've added the following conditional shortcode within the following view's "Loop Editor" section.
=> versteckter Link

[wpv-conditional if="( '[toolset_homepage_slideshow_count]' eq '1' )"]
                <style>
                  .glide__arrows { display:none; }
                </style>
		[/wpv-conditional]

Can you please confirm it works as expected now.

#2865675

Minesh,

This work beautifully. Thank you!

Saul