contao / core-bundle

[READ-ONLY] Contao Core Bundle
GNU Lesser General Public License v3.0
123 stars 58 forks source link

[RFC] Use the Intl extension to split words #1629

Closed ausi closed 6 years ago

ausi commented 6 years ago

As discussed in contao/core#2769.

This is a work in progress.

One problem I encountered is that it is currently possible to search in pages with different languages but we have to know the language in advance to know how to split the serch term. How should we do that?

leofeyer commented 6 years ago

You should probably base this on the 4.4 branch as it is a bugfix?

ausi commented 6 years ago

Is it? I think it’s a feature: adding support for non-latin languages to the search. Also, the behaviour will probably change slightly so I would prefer to add it in 4.7.

aschempp commented 6 years ago

we have to know the language in advance to know how to split the serch term. How should we do that?

well we do know the page language, don't we?

ausi commented 6 years ago

well we do know the page language, don't we?

Yes, we do. But currently it is possible to search across muliple languages at once, but if splitting words depends on the language this is no longer possible this way.

aschempp commented 6 years ago

You mean splitting on the input field, not on the page content to index?

ausi commented 6 years ago

Yes. The search input has to be splitted the same way, otherwise many results wouldn’t be found.

aschempp commented 6 years ago

I see. Well I guess we can only use the current page language …

leofeyer commented 6 years ago

Thank you @ausi.