Forums Forums Search & Filter Pro Add unique class or id to selections in multi type combo box

Viewing 5 posts - 1 through 5 (of 5 total)
  • Anonymous
    #249556

    Hi,

    Is there a way to add a custom class or id to each selection option in a multi-select combo box element,
    so that <li class=”search-choice”> will become <li class=”search-choice [custom css here]”> for each li option in the multi-select list?

    Trevor
    #249560

    Are you using the Chosen or Select2 script for comboboxes (it is an option in our plugin settings)? I would recommend Select2. If, after changing this, are you able to send me a live link/URL to your search page so I can take a look? I may have an idea.

    Anonymous
    #249583
    This reply has been marked as private.
    Anonymous
    #249587

    Thanks Trevor, I actually managed to find a css only solution for this by creating a css rule for title attribute, like this:

    li.select2-selection__choice[title="YOUR_CUSTOM_TITLE"] {
         ***Your Css Here***
    }
    Trevor
    #249589

    That was along the lines I was thing, so thanks for sharing. I will close this thread for now.

Viewing 5 posts - 1 through 5 (of 5 total)