Search on Custom Fields

This forum is for general questions about extensions for Joomla! 4.x.

Moderators: pe7er, General Support Moderators

Forum rules
Forum Rules
Absolute Beginner's Guide to Joomla! <-- please read before posting, this means YOU.
Forum Post Assistant - If you are serious about wanting help, you will use this tool to help you post.
Windows Defender SmartScreen Issues <-- please read this if using Windows 10.
Post Reply
mpigio
Joomla! Apprentice
Joomla! Apprentice
Posts: 5
Joined: Mon Aug 20, 2012 9:45 am

Search on Custom Fields

Post by mpigio » Tue Nov 30, 2021 2:42 pm

Hi, is it possible to make a search on custom fields?
I saw that by creating a field there is the "Filter" property in the general tab but then how does it appear in the search?
I installed the plugin + module "JL Content Fields Filter" but it doesn't filter on numeric fields and I can't enter the ranges as promised by the developer.
JA Megafilter is too expensive and I don't understand why it's possible to mark a custom field as a filter if it doesn't appear in the default search component!

Thanks in advance
Last edited by toivo on Tue Nov 30, 2021 8:17 pm, edited 1 time in total.
Reason: mod note: moved from 4.x General Questions

User avatar
Pnkr
Joomla! Enthusiast
Joomla! Enthusiast
Posts: 153
Joined: Thu Sep 01, 2011 7:26 am
Location: Athens, Greece

Re: Search on Custom Fields

Post by Pnkr » Wed Dec 01, 2021 7:16 am

Joomla default search also searches the values of custom fields. JL Content Fields Filter is a module to give specific filtering on custom fields lists.

For example if you have a custom field list with the values Cars, Planes, Boats, Bicycles.

If you search for the word Cars in joomla search, the search results will show all the articles that the word cars was in.

But that presupposes that the user knows that he can find some results by typing the word.

JL Content Filter on the other hand works like a filtering list of an eshop. It shows the values that the user can search (FOR LIST custom fields only) . So in that case the user will see a module with a selection box between cars, planes boats and bicycles and whatever he chooses it will see the corresponding result.

mpigio
Joomla! Apprentice
Joomla! Apprentice
Posts: 5
Joined: Mon Aug 20, 2012 9:45 am

Re: Search on Custom Fields

Post by mpigio » Wed Dec 01, 2021 7:33 am

Yes I know but isn't it a good feature for default search component of Joomla?

User avatar
sakiss
Joomla! Explorer
Joomla! Explorer
Posts: 285
Joined: Wed Aug 20, 2008 4:09 pm

Re: Search on Custom Fields

Post by sakiss » Wed Dec 01, 2021 11:51 am

Give a try at https://extensions.joomla.org/extension/jfilters/ .
It can be combined seamlessly with the Joomla's Smart Search.
Also it will allow you to filter using custom fields.
Last edited by imanickam on Thu Dec 02, 2021 3:31 am, edited 2 times in total.
Reason: As per the forum rule, changed the URL from the developer's URL to JED URL

joomhoo
Joomla! Apprentice
Joomla! Apprentice
Posts: 6
Joined: Tue Oct 05, 2021 10:14 am

Re: Search on Custom Fields

Post by joomhoo » Mon Dec 06, 2021 10:37 am

Pnkr wrote:
Wed Dec 01, 2021 7:16 am
Joomla default search also searches the values of custom fields.
It appears that this only happens when fields/fieldgroups are inserted into the Article editor's Content tab using {fieldgroup X} (unlike in J!3 where they were searchable without any extra effort).

Is there a way/extension to make custom field values searchable without manual insertion into articles?

- Maybe an extension that adds custom/additional content when an Article is saved?
- Or a clever script way (template override?) to insert the {fieldgroup X} code behind-the-scenes?

Its just that remembering to manually add them to each article each time is difficult for people to remember/do without fudging things. I'm looking for a way to automate things.


Post Reply

Return to “Extensions for Joomla! 4.x”