Skip Navigation

[Resuelto] Add a Featured Item on Custom Post Type Archive page

This support ticket is created hace 2 años. 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.

Hoy no hay técnicos de soporte disponibles en el foro Juego de herramientas. Siéntase libre de enviar sus tiques y les daremos trámite tan pronto como estemos disponibles en línea. Gracias por su comprensión.

Sun Mon Tue Wed Thu Fri Sat
- 9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 9: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/Hong_Kong (GMT+08:00)

Este tema contiene 2 respuestas, tiene 2 mensajes.

Última actualización por ellenB hace 1 año, 12 meses.

Asistido por: Luo Yang.

Autor
Mensajes
#2491461
cc-brokerage-featured.jpg

Tell us what you are trying to do?

I have a "Brokerage" Custom Post Type and I would like to have a "Featured" section that highlights a single boat in addition to the regular archive feed that shows all boats. I would like this Featured section to be located above the WordPress Archive Search. A screenshot of the design mockup showing the layout is attached.

I have tried adding a second WordPress Archive Loop inside of the WordPress Archive Output section and I get this error: "You need only one WordPress Archive Loop, please delete this one. Otherwise editor behavior will be unpredictable."

I have tried moving that new WordPress Archive Loop out of the WordPress Archive Output Section and it snaps back to it's original location.

I have tried using conditional logic to show the Featured item (indicated by a Featured checkbox custom field) and the result is mixed up with the rest of the results. I have also not been able to add a class to that conditional logic block (does not show up on the front end no matter how many times I save it).

I am using Toolset Types v3.4.17 and Toolset Blocks v1.6.3 with a GeneratePress child theme (using Gutenberg blocks).

Is there any documentation that you are following?

No, I didn't see anything in your documentation or the support ticket list that address my needs.

What is the link to your site?

enlace oculto

The site is password protected. The credentials to view the site are:

username: demo
password: cuttsandcase

#2492567
view2.jpg

Hello,

You can try these:
1) Follow our document to enable the legacy views
https://toolset.com/course-lesson/enabling-legacy-version-of-toolset-views/

2) Dashboard-> Toolset-> Views, setup a post view:
- query "Brokerage" posts,
- filter by the Featured custom field
- In view's loop, display "Brokerage" post information

3) Edit the Toolset WordPress Archive you mentioned above:

Add a view block-> Use existing View, choose the post view of step 2), see my screenshot view2.jpg

And test again

#2493163

This worked perfectly, thank you! My issue is resolved now.