Skip Navigation

[Résolu] Is it possible to check / set condition on post count in view?

This support ticket is created Il y a 5 années et 11 mois. 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.

Aucun de nos assistants n'est disponible aujourd'hui sur le forum Jeu d'outils. Veuillez créer un ticket, et nous nous le traiterons dès notre prochaine connexion. Merci de votre compréhension.

Sun Mon Tue Wed Thu Fri Sat
- 7:00 – 14:00 7:00 – 14:00 7:00 – 14:00 7:00 – 14:00 7:00 – 14:00 -
- 15:00 – 16:00 15:00 – 16:00 15:00 – 16:00 15:00 – 16:00 15:00 – 16:00 -

Supporter timezone: Europe/London (GMT+00:00)

Marqué : ,

Ce sujet contient 1 réponse, a 2 voix.

Dernière mise à jour par Nigel Il y a 5 années et 11 mois.

Assisté par: Nigel.

Auteur
Publications
#1167570

Hi i would like to add a conditional output in terms of the post count. In a view I would like to add different content if there is only one result.... is this possible?

#1167744

Nigel
Supporter

Les langues: Anglais (English ) Espagnol (Español )

Fuseau horaire: Europe/London (GMT+00:00)

Hi there

That should be possible, using the wpv-found-count in your wpv-conditional shortcode (see https://toolset.com/documentation/user-guides/views-shortcodes/#wpv-found-count).

Is that all you need, or do you need a demonstration?