Empty Smart Search titles

  • Posts: 191
  • Thank you received: 11
  • Hikashop Business
2 months 3 weeks ago #364441

-- HikaShop version -- : 5.1.1
-- Joomla version -- : 5.2.1
-- PHP version -- : 8.2.x

I noticed that smart search is working on the products, but if you look at the titles in the indexer all the titles are empty. It's not a big problem as search is working, but it looks odd.

Attachments:

Please Log in or Create an account to join the conversation.

  • Posts: 83193
  • Thank you received: 13439
  • MODERATOR
2 months 3 weeks ago #364442

Hi,

That's probably the variants indexed which you're looking at.
So no worries. It's normal that the title is empty for variants if you don't specify a name in them.

The following user(s) said Thank You: Rixters

Please Log in or Create an account to join the conversation.

  • Posts: 191
  • Thank you received: 11
  • Hikashop Business
2 months 3 weeks ago #364460

Thanks for the info!

Please Log in or Create an account to join the conversation.

  • Posts: 244
  • Thank you received: 22
  • Hikamarket Multivendor Hikashop Business Hikashop Essential
1 week 4 days ago #365351

Variants without a title cause problems in the front-end search results.

Apparently, the variant's main product name combined with characteristic options becomes the description, and the text for the title link is blank.



The <a href> is still there, but the title text is blank.
.

If I fill in each variant's title, it will be included as the title for the link.

Doing so on would be a rather massive undertaking as some of our products have 100s of variant combinations.

It seems like the description being generated for the variant in the index should be the title, especially since each variant can have a separate description.

Note one can click on the image and still get to the product, but it isn't intuitive.

Ideally, the link would also go to a variant URL (i.e.,/billiard-felt-cloth/simonis/product/860.html?cid=5852) and not the main product too, but mainly it is the title/description issue I wanted to point out.

Attachments:

Please Log in or Create an account to join the conversation.

  • Posts: 83193
  • Thank you received: 13439
  • MODERATOR
1 week 4 days ago #365354

Hi,

The reason why the name is not generated is because it would be computationally difficult.
Generating the name of a variant requires loading the parent product data, the characteristics data and the links between the variant and the values of the characteristics.
That's fine for one variant, or a bunch. But when you run an indexation, and you need to do this for each variant of each product, it takes a lot of time.
Also, this is normally not a problem because by default both the name AND the URL are displayed. For example:
i.imgur.com/O2IJeqS.png
So the name of the variant not being filled is not really a problem.
Since you don't have the URL on your website, I suppose that you must have a view override of the Smart search results page which removes it from there.
Check if you have the folder templates/YOUR_TEMPLATE/html/com_finder/search via FTP. If you do, try renaming that folder to something else in order to deactivate the view overrides for the smart search.
Then, try again, and you should have the results with the clickable URL, like by default on Joomla.
Also, note that the URL generated is the URL of the variant, not the URL of the product.
So, when I click on the URL you can see on my screenshot, I do end up on the page of the product with the variant automatically selected.
However, for this to happen, the id needs to available in the SEF URLs on your website, because the system needs to be able to provide the id of the variant in the URL. So, if you have the "Remove category and product ids from URLs" setting turned on in the HikaShop configuration, it would explain why it's not directing to the URL of the variant.

Please Log in or Create an account to join the conversation.

  • Posts: 244
  • Thank you received: 22
  • Hikamarket Multivendor Hikashop Business Hikashop Essential
1 week 2 days ago #365371

It appears the name is being calculated for variants and placed in the description of the results (p class=result__description).

i.e., "860HR™ Billiard Cloth- Pool (bed cloth & 6 rail cloths) Tournament Blue 10' "

In our case, the parent product name is "860HR™ Billiard Cloth."
And the characteristics are "Pool (bed cloth & 6 rail cloths) Tournament Blue 10'"

I checked for any template overrides before posting, but there are none.
I checked another site, and it has the same issue.
I tried the default Cassiopeia as well, and I got the same results.

Even in your example, the "blah blah" doesn't look like the title font/style/size (in the p class="result__title-text") but instead the description.
And it is in the title; shouldn't it be linked if it was the title?

Maybe I misunderstood how the description and the title are built.
But it appears to me that work is being done, just placed in the description field instead of the title.

I could turn the Result URL back so there was a visible link, but we'd rather have a name (shown in the description) in the title (<p class="result__title-text") to look like the rest.

If we could hide the variants in the search, that would solve this, too, but it doesn't appear that has been implemented yet.

Note I do have the category/product ID turned off, so that seems fine. I cannot turn them back on now; otherwise, it would break many things. However, I can live with that. As it stands, the issue is the one with the title/description above.

Please Log in or Create an account to join the conversation.

  • Posts: 83193
  • Thank you received: 13439
  • MODERATOR
1 week 2 days ago #365372

Hi,

On my end, the name of this variant is "Star stilettosGreen 4.5":
i.imgur.com/DvT5JhY.png
"blabla" is the text I've added to the description for the purpose of searching for that particular variant of the product.
And as you can see on my previous screenshot, the name of the variant doesn't appear at all.

So I thought your situation had to come from a template override.
I've looked deeper into the situation today and I was actually surprised that the name of the variant is actually already generated in the plugin. Looking at the code of the plugin, the generated name goes into the "summary" column of smart search, and the description goes into the "body" column of smart search, and I think that's where the problem is.
I've changed the code to use "title" and "summary" instead, and leave "body" out of the equation and it seems to work better:
i.imgur.com/8TjMGVg.png
So, I've made a patch on our end with the necessary changes. Download the install package of HikaShop on our website and install it on yours and you'll get the patch. Then, clear your index in the Smart search component, and click on the button to reindex all your content. The search results should then have the clickable generated name of the variants.

The following user(s) said Thank You: jazzmang

Please Log in or Create an account to join the conversation.

  • Posts: 244
  • Thank you received: 22
  • Hikamarket Multivendor Hikashop Business Hikashop Essential
1 week 2 days ago #365376

Confirmed quickly that the title and the variant characteristics are both now showing and linked.

Thanks!

The following user(s) said Thank You: nicolas

Please Log in or Create an account to join the conversation.

Time to create page: 0.081 seconds
Powered by Kunena Forum