Skip Navigation

[Resolved] Need Help With Parametric Search Filter – All Results Shown

The Toolset Community Forum is closed, for technical support questions, please head on to our Toolset Professional Support (for paid clients), with any pre-sale or admin question please contact us here.
This support ticket is created 9 years, 2 months ago. There's a good chance that you are reading advice that it now obsolete.
This is the community support forum for Types plugin, which is part of Toolset. Toolset is a suite of plugins for developing WordPress sites without writing PHP.

Everyone can read this forum, but only Toolset clients and people who registered for Types community support can post in it.

Sun Mon Tue Wed Thu Fri Sat
- 9:00 – 18:00 9:00 – 18:00 9:00 – 18:00 9:00 – 18:00 9:00 – 18:00 -
- - - - - - -

Supporter timezone: Asia/Karachi (GMT+05:00)

This topic contains 11 replies, has 2 voices.

Last updated by WILLILAM DOUGLAS 9 years, 1 month ago.

Assisted by: Waqas.

Author
Posts
#283913

I am trying to:

Display search results for specific criteria.

I visited this URL:

hidden link

I expected to see:

When using the filter it shows ALL of the products when several criteria are selected even if they don't meet ALL of the criteria checked.

Instead, I got:

The results show each product for every criteria selected instead of the specific products for all boxes checked.

#284059

Waqas
Supporter

Languages: English (English )

Timezone: Asia/Karachi (GMT+05:00)

Can you please provide a screen shot of your view in edit mode (full page readable)? So I can check the configurations of your view.

#285106
Edit-View-‹-UDTECH-USA-—-WordPress.jpg

Hi,

I've attached the screenshot.

I've been reading up about conditional HTML for this page and I think that is what I need. Basically something that says "display only results for all checked options" instead of displaying items which are only ONE of those checked options.

I'm just not sure how to do that. Would appreciate any help in getting that set up.

Thanks

#285238

Waqas
Supporter

Languages: English (English )

Timezone: Asia/Karachi (GMT+05:00)

Thank you for providing the screen shot. View looks fine and I have also observed it's working on the URL you mentioned in your first message.

Apparently, it looks fine, since I tried searching for single and multiple manufacturers, then I tried mixing the Categories and Manufacturers - it worked fine.

Can you please write some steps to reproduce the issue? or some test scenarios to observe the issue? It will help me aligning with your point of view, thanks.

#286113

Well the issue is that when you select multiple categories it's not limited to ALL the categories selected.

It's mainly showing when multiple filters are chosen. Try selecting ACTi, Dome, Indoor, and 2 MP and you will see what I mean. For instance, the results include 2 MP cameras that are not also ACTi, Dome, and Indoor. Does that make sense? The search results need to be implicit to all the options selected.

#286345

Waqas
Supporter

Languages: English (English )

Timezone: Asia/Karachi (GMT+05:00)

Thank you for explaining, I understand what did you mean.

I just checked your debug information again, looks like you are using a previous version of Views. Can you please upgrade Views to the latest version (1.7)? Since there have been several improvements and I am sure this issue will also be fixed. Because new version also includes internally improved queries and filters.

Please let me know if this helps, thanks.

#287949

Hi, I upgraded to the new Views but the error is still occurring.

Is there a specific filter I need to change in the new Views?

Thanks

#287954

Also there is a strange error occurring when I click on a product it takes me to a single product page but the product is always the same one, I have no idea why this is occurring.

I tried to open another topic but the option wasn't there.

Thanks.

#288099

Waqas
Supporter

Languages: English (English )

Timezone: Asia/Karachi (GMT+05:00)

Can I ask you for a temporary access to your site? So I can look for more details and can try a fix.

I have enabled your next reply as private, please input all details in that area. Also mention the Views, Pages and CPTs in question.

Please remember to take backup of your site, before proceeding.

#288356

Waqas
Supporter

Languages: English (English )

Timezone: Asia/Karachi (GMT+05:00)

Thank you for providing the access information. Please allow me some time to work on this. I will update you as soon as I find a solution.

#288643

Waqas
Supporter

Languages: English (English )

Timezone: Asia/Karachi (GMT+05:00)

I have tried to figure out the issue, and apparently I realized that, the query which is responsible to filter the results, uses IN() function of MySQL, which is meant to select "any" available result from the selected taxonomies.

For example, if a product falls under the categories 1MP, Indoor and Box. Searching for 'Indoor' will include this product in the results. This is kind of loose-search, which has broader results.

For a test case, I have made a little change to the Query Filters of your view. I have just changed 'IN' with 'AND' for 'Product Categories' filter. Now, it results only for such results where all selected categories are matched. This tightens the search and narrow downs the results.

If you would like to revert the change, simply change 'And' with 'IN' for 'Product Categories' query filter.

I hope this helps understanding the scenario.

#288808

Thank you. Yes I thought maybe that was the issue. I saw that option within Views but I did not apply it because I wasn't sure if that was the correct option.

Thank you for fixing it, I will check it to make sure it's correct but I think that is what was missing.

The forum ‘Types Community Support’ is closed to new topics and replies.

This ticket is now closed. If you're a WPML client and need related help, please open a new support ticket.