Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

More Filter Options? #7

Open
ghost opened this issue Mar 20, 2015 · 4 comments
Open

More Filter Options? #7

ghost opened this issue Mar 20, 2015 · 4 comments

Comments

@ghost
Copy link

ghost commented Mar 20, 2015

How would you go about adding check boxes that target that items tag/category...etc?

and is it possible to have a message display when theres nothing found?

@chromawoods
Copy link
Owner

For your first question, I would need more info on how it should suppose to work. I think I understand what you mean and you might be able to use the filterCategory option, but I'm not sure.

For your second question, you can use the onFilterComplete callback and just check length on the received items parameter. If zero, you can do whatever you want.

@ghost
Copy link
Author

ghost commented Mar 21, 2015

Sorry, was kinda late when i typed that,

Basically i have a search bar that allows to search the list, but id like it so i can use checkboxs or even a range bar to better filter the list, i plan to use wordpress therefore you can have tags on each list item

for example have a checklist with
Easy
Medium
Hard

and when a user ticks or unticks it filters the list more

Also is it possible to add a message if nothing is on the list? and the effects dont seem to be working so i need to include the easing jquery script?

@chromawoods
Copy link
Owner

I have just updated the live demo page with some examples that are relevant to you. Especially have a look at example 7 and 9. It should solve your problems.

What effects have you tried? Maybe put together a jsbin or something?

@ghost
Copy link
Author

ghost commented Mar 25, 2015

Hello,

Sadly i still cant get it to work,

this is my filtering
<ul id="advance"> <li><input type="checkbox" value="novice">Novice</li> <li><input type="checkbox" value="medium">Medium</li> <li><input type="checkbox" value="hard">Easy</li> </ul>

this is based off the demo page

` var insta = $('#advance').instaFilta();

    insta.filterCategory('easy');

    insta.filterCategory('medium');

    insta.filterCategory('hard');`

and this is my function for the search bar

` $(function() {

        $('#cata-search').instaFilta({
            scope: '#container',
            targets: '.item',
            sections: '.asset-cata',
            markMatches: true
        });

    });

`

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant