AND selector jQuery

javascript, jquery

Solution

Yes you can do that, you are actually looking for `combined attribute selector`.

Try,

$('div.job[data-province!="'+province+'"][data-employment!="'+employment+'"][data-education!="'+education+'"][data-branch!="'+branch+'"]').fadeOut('slow');

Problem

Is it possible to use an AND selector in jQuery? I am trying to filter through results where I need multiple selectors to be true. This is what I use but instead of "OR" so the "," I use I want to use "AND". ``` $('div.job:not([data-province="'+province+'"])', 'div.job:not([data-employment="'+employment+'"])', 'div.job:not([data-education="'+education+'"])', 'div.job:not([data-branch="'+branch+'"])').fadeOut('slow'); ```

Original source