?
avatar hakanara
hakanara
31 Jul 2017

In other words, is the search string is found in the title of an article, I expect it to be displayed above the other results, (above the matches in the content).
This issue is separated from #11996

Steps to reproduce the issue

Activate the search content plugin and search a word that is found in one of the titles of an article.

Expected result

If the word in the title matches, that should be displayed above the other results where the match is within the content. (this is generally what we are used to see from Google search results.)

Actual result

Articles are ordered according to the article id but not according to the matching titles first and then the matching content.

Additional comments

Maybe SQL and Joomla gurus find a way to merge two search queries. The first searches in the titles, second searches in the content. The first query results are displayed first and then the second query results come.

I have also set up a fresh Joomla installation with test data (Teaching Joomla in English). After setting it up, I have searched the Word Joomla in the search box.

Here is the order of the search results:

Templates
Protostar
Plugins
Park Blog
Navigation Modules
Modules
Languages
Joomla!
Extensions

As you see the article with Joomla is not ranking 1st but 8th.
I am talking about "search content plugin" which is available on this test site by default.

avatar hakanara hakanara - open - 31 Jul 2017
avatar joomla-cms-bot joomla-cms-bot - change - 31 Jul 2017
Labels Added: ?
avatar joomla-cms-bot joomla-cms-bot - labeled - 31 Jul 2017
avatar hakanara hakanara - change - 31 Jul 2017
The description was changed
avatar hakanara hakanara - edited - 31 Jul 2017
avatar franz-wohlkoenig franz-wohlkoenig - change - 31 Jul 2017
Category com_search UI/UX
avatar tonypartridge
tonypartridge - comment - 31 Jul 2017

Interesting, off the top of my head the query is a single query if this or that. Not 1 then 2, since it's duplicated queries for a simple query. An interesting point though.

avatar brianteeman
brianteeman - comment - 31 Jul 2017

This has come up before. The problem is with the sql query producing a single set of results and then sorting by a single field.

The only way you can achieve what you are asking for is to use Smart Search and not search. That was written specifically for this requirement

avatar franz-wohlkoenig franz-wohlkoenig - change - 1 Aug 2017
Status New Discussion
avatar Shazrina1994
Shazrina1994 - comment - 1 Aug 2017

i am a new person to open source project, Joomla and I like to work on this issue

avatar tonypartridge
tonypartridge - comment - 1 Aug 2017

@Shazrina1994, then please do! But as @brianteeman said it was solved with using Smart search instead of Search which creates an index of results.

avatar Shazrina1994
Shazrina1994 - comment - 1 Aug 2017

yah @tonypartridge I got it and working on that Search

avatar hakanara
hakanara - comment - 1 Aug 2017

Thank you @Shazrina1994 . I prefer to use this search since smart search stores massive data in the database. Personally I still have no idea why smart search is not an addon but a core component. It creates many tables as well.

avatar tonypartridge
tonypartridge - comment - 1 Aug 2017

Because it is a heavily optimised search engine for Joomla! Rather than a heavy search component like what you are using. If you have thousands of articles and other content and are searching the whole database every time someone has a query it adds a ton of overhead to the system, opposed to a refined and optimised search system.

Many thanks
Tony

On 1 Aug 2017, 15:51 +0100, hakanara notifications@github.com, wrote:

Thank you @Shazrina1994 . I prefer to use this search since smart search stores massive data in the database. Personally I still have no idea why smart search is not an addon but a core component. It creates many tables as well.

You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub, or mute the thread.

avatar mbabker
mbabker - comment - 1 Aug 2017

I prefer to use this search since smart search stores massive data in the database.

That's kind of how search platforms work though. They store an index of the data on your site in a specialized set of tables (or whatever the platform uses for storage) and query that when you issue a search.

com_search plugins are really just a simple "query this table, see if these fields contain search term", they don't have the logic to be able to do weighted searches or order results in a way that would be most logical for the user.

avatar hakanara
hakanara - comment - 1 Aug 2017

@tonypartridge , @mbabker Thank you very much for the explanations. I understand that you are not very optimistic about brining the matching titles at the first position with the standard search plugin. Therefore, I will also try to see how the other component works though. Your explanations made me curious. Thank you very much for all the time you have spent on Joomla :-)

avatar tonypartridge
tonypartridge - comment - 2 Aug 2017

You are very welcome. Can we close this, given the answer is to use Smart Search

avatar franz-wohlkoenig franz-wohlkoenig - change - 3 Aug 2017
Status Discussion Closed
Closed_Date 0000-00-00 00:00:00 2017-08-03 04:16:31
Closed_By franz-wohlkoenig
avatar joomla-cms-bot joomla-cms-bot - change - 3 Aug 2017
Closed_Date 2017-08-03 04:16:31 2017-08-03 04:16:32
Closed_By franz-wohlkoenig joomla-cms-bot
avatar joomla-cms-bot joomla-cms-bot - close - 3 Aug 2017
avatar joomla-cms-bot
joomla-cms-bot - comment - 3 Aug 2017
avatar franz-wohlkoenig
franz-wohlkoenig - comment - 3 Aug 2017

closed as stated above.


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/17361.

Add a Comment

Login with GitHub to post a comment