User tests: Successful: Unsuccessful:
Pull Request for Issue #44549 .
Add option to finder plugin "Smart Search - Content" for excluding search for author's name in article field "created by".
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.
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.
The search results will only show those articles in which the author's name is included in the article content text.
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
Status | New | ⇒ | Pending |
Category | ⇒ | Administration Language & Strings Front End Plugins |
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
I have tested this item ✅ successfully on be0a12b
Expected Result: Only articles that mention "Author A" within the content should appear in the search results. Articles authored by "Author A" but without their name in the content should be excluded.
@shrutidhole123 Can you please always provide the reasons for a unsuccessfully test so developer can investigate?
I have tested this item ✅ successfully on be0a12b
Works as described
I have tested this item ✅ successfully on be0a12b
the code does what is expected. But what is the sense of it? If I search for an author I would expect that it appears also if not being mentioned in the test of the article.
I have tested this item 🔴 unsuccessfully on be0a12b
This is incomplete.
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.
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 pull request has been automatically rebased to 6.0-dev.
Title |
|
Labels |
Added:
Feature
Language Change
Updates Requested
PR-6.0-dev
|
Build | 5.2-dev | ⇒ | 6.0-dev |
Sorry, I missed the conversation here the last weeks. Thanks for testing, everybody!
I have tested this item 🔴 unsuccessfully on be0a12bThis is incomplete.
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.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.
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?
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?
Nevertheless, I'm happy to adapt my fix (which I still have to do for J 6.0 anyway) so that the created_by_alias field would also be excluded if you switch the search for created_by to NO in the plugin, as shown in my first screenshot.
I wouldn't introduce a second radio button for this, as that would only confuse most users who don't even know that there is a difference between ‘Created By’ and ‘Created by Alias’.
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
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.
Thank you, I got it now. It just never occured on my Joomla websites, but this might be useful for other sites.
My point is that if you want to exclude created_by from the search then you would also want to exclude created_by_alias
Yes, thank you for the hint. I will do so in a few days (by just moving one line of code).
Personally I think its a daft feature request but if its to be done then it should be done properly
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.
I will be happy if this small feature of the finder plugin finds its way into Joomla 6.
Labels |
Removed:
Updates Requested
|
I have tested this item ✅ successfully on be0a12b
Tested on top of 5.2.2.
With the xml default="1" we are having the current behaviour, with the plugin set to "No" the Article's Author are no longer displayed.
Nice fix.
This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/44554.