Skip Navigation

[Resolved] List posts by a few parameters

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 thread is resolved. Here is a description of the problem and solution.

Problem:

I have categories: printers, monitors, keyboards.
Each category has posts.
One post is one piece of hardware, for example a monitor.
Each post has additional fields that define parameters. These are the select fields. For example, the diagonal of the screen.

I need to do a page where the user chooses from the drop-down lists:
- printer (laser or ink)
- keyboard (wireless, with cable)
- monitor (17 ", 18" etc.)

After selecting the options, will be displayed a page that contains the equipments with the given properties.
This page is to be used as a offer generator for the user.

Is it possible to do it with Toolset at all?

Solution:

you can create a view to query printer posts (laser or ink) once, then query keyboard posts (wireless, with cable) with another view...

In you case, I suggest you try these:
1) Create a view "printers", filter by:

a) categories is "printers":
https://toolset.com/documentation/user-guides/filtering-views-by-taxonomy/

b) custom field "laser or ink" from search form

https://toolset.com/documentation/user-guides/front-page-filters/
put above page into a page, where user can search for printer posts (laser or ink)

2) Same as above Create different view "keyboard", "monitor" and so on.

Relevant Documentation:

https://toolset.com/documentation/user-guides/front-page-filters/

This support ticket is created 6 years, 10 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 – 13:00 9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 -
- 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 -

Supporter timezone: Asia/Hong_Kong (GMT+08:00)

Tagged: 

This topic contains 4 replies, has 2 voices.

Last updated by tomaszB-4 6 years, 10 months ago.

Assisted by: Luo Yang.

Author
Posts
#614912

Hi!
I have a puzzle, I do not know how to make some kind of offer generator. Can someone give me a clue?

I have categories: printers, monitors, keyboards.
Each category has posts.
One post is one piece of hardware, for example a monitor.
Each post has additional fields that define parameters. These are the select fields. For example, the diagonal of the screen.

I need to do a page where the user chooses from the drop-down lists:
- printer (laser or ink)
- keyboard (wireless, with cable)
- monitor (17 ", 18" etc.)

After selecting the options, will be displayed a page that contains the equipments with the given properties.
This page is to be used as a offer generator for the user.

Is it possible to do it with Toolset at all?
I will be grateful for every clue.

#615104

Hi,

There isn't exact same feature within Views plugin, you can create a view to query printer posts (laser or ink) once, then query keyboard posts (wireless, with cable) with another view...

In you case, I suggest you try these:
1) Create a view "printers", filter by:
a) categories is "printers":
https://toolset.com/documentation/user-guides/filtering-views-by-taxonomy/
b) custom field "laser or ink" from search form
https://toolset.com/documentation/user-guides/front-page-filters/
put above page into a page, where user can search for printer posts (laser or ink)

2) Same as above Create different view "keyboard", "monitor" and so on.

#615967

Thanks Luo for the answer!

Oh, that is the solution - custom search!
https://toolset.com/documentation/user-guides/front-page-filters/

But is it possible:
- Custom search is built from three select fields.
- The user has to choose something from each of these fields and only then may click the search button.

Is it possible to force it somehow?

best regards
Tomasz

#616205

There isn't such a built-in feature within Views plugin, it needs custom codes, for example, when user click submit button, you can setup JS codes to trigger a JS function:
hidden link

Then get the value of those three fields, check if user choose something from each of these fields
hidden link

#616261

Thanks a lot Luo for this tips!

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