Skip Navigation

[Resuelto] Adding chosen search filters under search to remove after search populates

This support ticket is created hace 4 años, 8 meses. 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
- 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)

Este tema contiene 3 respuestas, tiene 2 mensajes.

Última actualización por Minesh hace 4 años, 8 meses.

Asistido por: Minesh.

Autor
Mensajes
#1525493

AG
search.jpg

Tell us what you are trying to do? I'm hoping to have something like I've created on a screenshot below. Once the user searches, the filters will show up below at individual links that the user can then click the x next to it to remove it. Is this possible?

Is there any documentation that you are following? No documentation. I've done a quick search but nothing really comes up as I'm not sure how to search for this sort of functionality.

Is there a similar example that we can see? enlace oculto

What is the link to your site? It is currently a staging site and I can get the info for you but don't want it to be up live on the web. Let me know if I can send that to you?

#1526929

Minesh
Supporter

Idiomas: Inglés (English )

Zona horaria: Asia/Kolkata (GMT+05:30)

Hello. Thank you for contacting the Toolset support.

There is no such feature available to add such custom styles filter with views.

However - please check the following ticket that may help you and you can implement that chosen-select if that fits in to your requirement.
=> https://toolset.com/forums/topic/limit-number-of-options-visible-in-search-dropdown-box-taxonomy-scroll-list/#post-1136059

#1530657

AG

Thanks for looking into this. The article you linked to doesn't really have anything to do with what I wanted unfortunately but it is a handy feature, how can this be implemented to my speakers category list I have?

#1531857

Minesh
Supporter

Idiomas: Inglés (English )

Zona horaria: Asia/Kolkata (GMT+05:30)

Do you mean that you want to apply the solution I shared with the following reply on your site?
=> https://toolset.com/forums/topic/limit-number-of-options-visible-in-search-dropdown-box-taxonomy-scroll-list/#post-1136059

If yes:
- You need to add the following code to your current theme's functions.php file:

function enqueue_chosen_jquery() {
    wp_register_style( 'custom_chosencss', '<em><u>enlace oculto</u></em>', false, '1.1.0', 'all' );
    wp_register_script( 'custom_chosenjs', '<em><u>enlace oculto</u></em>', array( 'jquery' ), '1.1.0', true );
    wp_enqueue_style( 'custom_chosencss' );
    wp_enqueue_script( 'custom_chosenjs' );
    }
add_action( 'wp_enqueue_scripts', 'enqueue_chosen_jquery' );

And add the following code to your view's Search and Pagination section's JS box:

jQuery(document).ready(function($){
   $(".chosen-select").chosen({
    no_results_text: "No items found!",
    max_selected_options: 5
   });
});

And make sure to add the class "chosen-select" to your speaker's category filter.

If you do not know how to do it, please feel free to share access details and problem URL where you added your view and I would be happy to fix it for you.

*** Please make a FULL BACKUP of your database and website.***
I would also eventually need to request temporary access (WP-Admin and FTP) to your site. Preferably to a test site where the problem has been replicated if possible in order to be of better help and check if some configurations might need to be changed.

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