How to filter on min. age and max. age?

  • Posts: 41
  • Thank you received: 1
9 years 8 months ago #193500

-- HikaShop version -- : 2.4.0
-- Joomla version -- : 3.4
-- PHP version -- : 5.3.29
-- Browser(s) name and version -- : Firefox 35.0.1
-- Error-message(debug-mod must be tuned on) -- : no errors

I use a filter with minimum age and maximum age, both can be between 4...18 year.
Example: A product is used for ages between 9 and 14 so these ages are set as custom fields.
When a shopper is filtering on min age= 9 and max age =15 he will not see this product.
He will only see this product if he filters on the exact numbers (9 and 14).
This is not what a shopper expects.

I want to show this product also if he filters from 4 to 10 or from 12 to 18.
Is this possible? How?
Which php file do I have to change?

Please Log in or Create an account to join the conversation.

  • Posts: 13201
  • Thank you received: 2322
9 years 8 months ago #193543

Hi,

Please give us a screenshot of the settings of your filter.
Are you using a cursor filter ? It seems to be indicated in your case.

Please Log in or Create an account to join the conversation.

  • Posts: 41
  • Thank you received: 1
9 years 8 months ago #193830

Hello Xavier,
In the original VM webshop they used a dropdown for minimum age and maximum age, so I did this als o in Hikashop.
See pictures.

Attachments:

Please Log in or Create an account to join the conversation.

  • Posts: 13201
  • Thank you received: 2322
9 years 8 months ago #193853

Hi,

Yes this filter allow to filter on one value, to filter on a range, you can potentially use a multidropdown, or the cursor filter.

Please Log in or Create an account to join the conversation.

  • Posts: 41
  • Thank you received: 1
9 years 8 months ago #194461

Hello Xavier,
I have tested the multidropdown, thats nice, but not the solution.
In my database I have only a minumum age and a maximum age. The filter works exact, and that is not working for a customer.

Example: I have a childrens book suitable for 6 to 10 years. (In my database is min age= 6 and max age = 10)
The customer has a kid from 8 years. He would check on min age 7 and max age 9, the book will not show up, because you have to insert the exact min. age and max. age numbers.
And if the customer filters on min age 6 and max age 8 he also do not find the book.

I am still thinking about a right solution and will ask my customer (the webshop owner) her opinion.

Please Log in or Create an account to join the conversation.

  • Posts: 41
  • Thank you received: 1
9 years 8 months ago #194462

Hello Xavier,

What will be a good solution for products whitch are mentioned for a certain age group like children (example: 6-10 years)
So, what do you suggest to solve this problem?

The min age and max age is not a good solution as exact numbers in the database, because of the exact match you need. One field with 'age' could be a solution?

I like the cursor type (4..18 years) But how do I put a value (age - example: 6-10 years) in Hikashop to a product?

Please Log in or Create an account to join the conversation.

  • Posts: 41
  • Thank you received: 1
9 years 8 months ago #194483

Hello Xavier, I do have a solution, but it is not working OK.
This is what I do:

I made a new custom field 'leeftijd' (age) and put all values in it (see screenshot)
I also made a new filter of the type: cursor (4..18)
It looks if it works fine, but not always.
I have product A (7-12) and product B (7-15)
If I filter between 7 to 15 I will see both products, that's OK.
But if I filter between 8 and 15 I do not see any products.
Do I filter between 6 and 15 I will see both products, that's OK.

It seems Hikashop filter needs the lowest value you have entered in custom-field.
So I think this is a bug.

Attachments:

Please Log in or Create an account to join the conversation.

  • Posts: 13201
  • Thank you received: 2322
9 years 8 months ago #194463

Hi,

You will need two cursors, one for the min age and one for the max age.
If you set them as dynamic, so when filtering on one of the two values it will adapt the values available for the other cursor.

Please Log in or Create an account to join the conversation.

  • Posts: 41
  • Thank you received: 1
9 years 8 months ago #195123

Hi Xavier,
I have tested with 2 cursors: 1 for min age and 1 for max age and both dynamically. The result is very strange, because the values above the cursors are changing, it should always be from 4...18 years. So this is not working.
My solution with one cursor and all ages in one custom-field (age) looks like the best for the web-visitor.
But the filtering is not working good.

Because this is important for the webshop, I need a solution. (The VM webshop from my customer has this solution... and I suggested to move to Hikashop.... :huh: ) I will ask it in a JUG.

Please Log in or Create an account to join the conversation.

  • Posts: 13201
  • Thank you received: 2322
9 years 8 months ago #195180

Hi,

You have to disable the "dynamic" option then.
This way the values will always stay 4 ... 18

Please Log in or Create an account to join the conversation.

Time to create page: 0.062 seconds
Powered by Kunena Forum