-
-
Notifications
You must be signed in to change notification settings - Fork 3.8k
[6.1] Exclude search results 'created_by' #44554
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: 6.1-dev
Are you sure you want to change the base?
[6.1] Exclude search results 'created_by' #44554
Conversation
|
I have tested this item ✅ successfully on be0a12b This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/44554. |
|
The way you implemented this, this definitely is a new feature and needs to go into 5.3. I'm going to discuss this in the CMS maintenance team if we expect the existing option for the taxonomy to also remove this from the search index. In that case this might be considered a bug and can be fixed in 5.2. In any case I'd like to see this handled for all things we are adding to the index (author, category, tags) and for all core finder plugins. |
|
I'm sorry, but I will have to handle this as a new feature and as I said, I would need more than just one "random" part of the article to be able to be switched off. I'm moving this to 5.3 for now and will switch the label to feature instead. Please change it as I described above. |
|
I have tested this item 🔴 unsuccessfully on be0a12b This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/44554. |
|
I have tested this item ✅ successfully on be0a12b This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/44554. |
|
@shrutidhole123 Can you please always provide the reasons for a unsuccessfully test so developer can investigate? |
|
I have tested this item ✅ successfully on be0a12b This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/44554. |
|
I have tested this item ✅ successfully on be0a12b This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/44554. |
|
I have tested this item 🔴 unsuccessfully on be0a12b
If, and its a big if, you think its necessary to exclude the created_by from the search then you also need to exclude created_by_alias otherwise the same "problem" is still present This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/44554. |
|
This pull request has been automatically rebased to 6.0-dev. |
|
Sorry, I missed the conversation here the last weeks. Thanks for testing, everybody!
No, I don't think that it is necessary to exclude the created_by from the search, but it would be quite useful to offer the possibility. Please note that the fix does not change the search as it is, but it offers the possibility to hugely improve search results for some websites. Because in some cases you just don't want to search by the author's name (the name could also be a common word) and find all articles which he or she has written regardless of the article content itself. As for created_by_alias, my fix seems not to affect it, because - strange enough! - this field in DB table #__content is always empty in all of my joomla sites! What's going on here? Is this field needed at all in core? |
Thanks for the clarification, but usually the users already have names in the created_by field, don't they? |
Think of a webmaster creating an article for the CEO. It should say the author is the CEO not the webmaster. That is what the field is used for. My point is that if you want to exclude created_by from the search then you would also want to exclude created_by_alias Personally I think its a daft feature request but if its to be done then it should be done properly |
Thank you, I got it now. It just never occured on my Joomla websites, but this might be useful for other sites.
Yes, thank you for the hint. I will do so in a few days (by just moving one line of code).
Totally agree (with the second part of your comment ;) |
|
I updated my pull request to include also the field of 'created by alias' - thanks once again to @brianteeman for the valuable advice. |
Co-authored-by: Quy Ton <quy@nomonkeybiz.com>
…thub.com/pixelhexe/joomla-cms into finder-plugin-content-exclude-created-by
|
This pull request has been automatically rebased to 6.1-dev. |


Pull Request for Issue #44549 .
Summary of Changes
Add option to finder plugin "Smart Search - Content" for excluding search for author's name in article field "created by".
Testing Instructions
You'll need some articles written by an author and in one or several articles insert the author's name as normal content (article text). Add a finder / smart search into your site as you would generally do. For example add a menu item with menu item type "Search" without special filters or advanced features. Don't forget to index your content in backend in the search component.
After the changes of this pull request you'll have an additional option in the finder plugin content "Include articles 'created by' (author's name)?" with default value "yes". Everything remains as it is if this option is not changed.
For testing purposes switch the new option to "no" and save it. Then you'll need to clear your search index and reindex content.
In frontend, search for the author's name which you included in the article text of one or more articles.
Actual result BEFORE applying this Pull Request
The search results will show all articles created by this author.
Users are confused because they don't know how these search results come about - unless the site is configured so that the authors are always visible in the articles, which is often not the case.
They would expect only those articles to be listed where the author's name appears in the normal article text.
Expected result AFTER applying this Pull Request
The search results will only show those articles in which the author's name is included in the article content text.
Link to documentations
Please select:
Documentation link for docs.joomla.org:
No documentation changes for docs.joomla.org needed
Pull Request link for manual.joomla.org:
No documentation changes for manual.joomla.org needed