Support Forums - Classified Ads Script Osclass

General osclass questions => General discussion => Topic started by: Anthony Marshall on February 08, 2021, 08:16:30 PM

Title: Searching on Custom Fields
Post by: Anthony Marshall on February 08, 2021, 08:16:30 PM
Hello,

I have added a custom field to my site that has the options of "Dealer" or "Private Party".

If I select a category then I can filter the results by one of those two options.

If I do not select a category it will not let me filter by those. I have tried adding this to the URL and it doesn't work - "&meta[7]=Private+Party"

So my question is how to allow the users to filter the "latest listings" by this custom field without having to select a category first?

Thanks,
Anthony
Title: Re: Searching on Custom Fields
Post by: MB Themes on February 09, 2021, 09:45:47 AM
@Anthony Marshall
Reason is that if no category is selected, custom fields are not included at all.
This is to avoid having too many custom fields in sidebar those are not related to each other just because no category has been selected.
Title: Re: Searching on Custom Fields
Post by: Anthony Marshall on February 09, 2021, 08:21:04 PM
@Anthony Marshall
Reason is that if no category is selected, custom fields are not included at all.
This is to avoid having too many custom fields in sidebar those are not related to each other just because no category has been selected.

Hi @MB Themes

Yes I understand how it is working but I would like to have that particular custom field to search on without having to select a category. I will look at the code and see if I can figure it out

Thanks,
Anthony
Title: Re: Searching on Custom Fields
Post by: Anthony Marshall on February 09, 2021, 08:22:15 PM
@MB Themes - No hard feelings I hope  :)
Title: Re: Searching on Custom Fields
Post by: cartagena68 on February 10, 2021, 04:20:57 AM
Maybe this can help you with that
https://docs.osclasspoint.com/how-to-extend-fields
Title: Re: Searching on Custom Fields
Post by: Anthony Marshall on February 10, 2021, 03:30:50 PM
Maybe this can help you with that
https://docs.osclasspoint.com/how-to-extend-fields

Thank you!