facebook

Select list reset

  1. MobiOne Archive
  2.  > 
  3. Getting Help – General
Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #341015 Reply

    paulD
    Member

    Hi everyone

    You know some days its like wading through treacle……

    Anyway hoping you web dev wizz kids can help me out (again)! I’m using a custom css file to toggle the background color of the select list widget in my app. Works great but what i need to do is have a reset button which resets the whole select list item back to its default background color and unchecked state without having to select each list item.

    the css is

    /* set SelectList selected items background to green */
    .m1-selection-list > li.m1-selected.m1-icon-2 {
      background-color: rgb(51,204,0);
    }

    As always I’ve found a zillion different answers on tinternet abd have tried using jQuery addClass, removeClass without any success. I would like to do it per list item as my app as multiple lists if possible.

    Attachments:
    You must be logged in to view attached files.
    #341020 Reply

    Stu Wade
    Member

    Hi Paul,

    As you know, I am no expert, but …
    Vadim recently showed me how to remove the ‘select’ attribute using removeClass. I can give you the hairy details if it will help. As far as doing it on a per list rather than a per listItem basis, I hold out little hope, but I recall seeing something on the lines of forEach.selectedItem which would lighten the code load … Sorry cant remember the details for that one, but it might help direct your search.

Viewing 2 posts - 1 through 2 (of 2 total)
Reply To: Select list reset

You must be logged in to post in the forum log in