Textpattern CMS support forum
You are not logged in. Register | Login | Help
- Topics: Active | Unanswered
Incomplete search
Why are some words not found by Textpattern search?
The website is still under development, no English version so far, sorry. For an example, there are two sentences in the first paragraph on this page (in Lithuanian language):
km.on.lt/kadastriniai-matavimai/
Įmonėje dirba aukštos kvalifikacijos matininkai, inžinieriai geodezininkai ir kadastrininkai. Matavimams ir topografijai taikomi šiuolaikiniai geodeziniai ir lazeriniai prietaisai, specializuota programine įranga.
Let us look for words in plain ASCII letters only.
- A query for dirba is successful (found on the second link of http://km.on.lt/?q=dirba);
- matininkai are there too, in a right place;
- the third word (in the end of the same sentence), kadastrininkai — not found;
- Matavimams (in a beginning of the second sentence) — found again;
- but the next word taikomi (witch was already excerpted in search results by the previous query) — not found.
I am confused, please point me to the right way.
Offline
Re: Incomplete search
Where does the text of km.on.lt/kadastriniai-matavimai/ (containing the word “kadastrininkai”) is coming from? The search for dirba links to km.on.lt/kadastriniai-matavimai/kadastriniai-matavimai, not km.on.lt/kadastriniai-matavimai/. Edit: though finally the first link is redirected to the second one.
Offline
Re: Incomplete search
Yes, because it is sticky article and thus is 301 redirected to its section’s “Kadastriniai Matavimai” URL.
Last edited by Vienuolis (2017-11-13 05:37:22)
Offline
Offline
Re: Incomplete search
Yes, ‘sticky’ is set there:
<txp:article searchsticky="1" limit="25" wraptag="dl">
<dt><strong><txp:search_result_title /></strong></dt>
<dd><txp:search_result_excerpt /></dd>
</txp:article>
Offline
Re: Incomplete search
New I’ve expanded the limit to 999 (although the word ‘kadastrininkai’ in this website is mentioned only once) — not found yet.
Offline
Re: Incomplete search
Weird, if I copy the text of this article, kadastrininkai
is found for me. Check if <txp:if_search_results />
in search_form
has min
attribute by any chance? It looks like the search on your site outputs only multiple matches.
Offline
Re: Incomplete search
Neither min
nor max
was set, as by default. Now I’ve set <txp:if_search_results min="1">
— the same search results, ‘kadastrininkai’ still not found.
Offline
Re: Incomplete search
Wow! The search works correctly now, when I have set min="0"
. Thank you very much, dear Oleg!
Offline
Re: Incomplete search
No, wait Vladas, it’s still weird that the default min="1"
works for me, but not for you. Could you run the diagnostics, to see if some files have not been modified? Thanks!
Offline
Re: Incomplete search
Two warnings, both for my non-Apache webserver (Hiawatha) only. Diagnostics: Pre-flight check:
Clean URLs are only supported on Apache, use at your own risk. (i)
.htaccess file is missing (i)
Offline
Re: Incomplete search
Now (with min="0"
) you land on the search page even if there is no search results. Something strange is happening on your site, but I can not reproduce the issue. By any chance, have you put <txp:if_search_results />
before <txp:article />
? This will work in 4.7, but not in 4.6.2.
Edit: my bet is that you have <txp:article pgonly="1" />
without searchsticky
attribute before <txp:if_search_results />
. If so, try to add searchsticky="1"
and remove min
.
Offline