Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#1 2011-01-12 10:26:55

bmwg
Member
Registered: 2010-04-06
Posts: 39

Search doesn't return any results (even though it should)

Hi,
I’ve tried to include a search form to a webpage but it doesn’t return any results. Even though I search for words that occur in articles which are in sections where search is activated.
<txp:search_result_count /> returns 0 and I don’t get any articles.
Do I have to activate something else?

Offline

#2 2011-01-12 10:30:00

colak
Admin
From: Cyprus
Registered: 2004-11-20
Posts: 9,254
Website GitHub Mastodon Twitter

Re: Search doesn't return any results (even though it should)

Can you post the code?

somewhere in your template you should have something like

<txp:if_search_results>
<p class="line">You searched for <strong><txp:page_url type="q" /></strong>. <txp:search_result_count />.</p>
<txp:else />
<p>Your search for <strong><txp:page_url type="q" /></strong> did not match any documents.</p>
</txp:if_search_results>
<txp:article limit="999" searchall="0" />
</txp:if_search>

Yiannis
——————————
NeMe | hblack.art | EMAP | A Sea change | Toolkit of Care
I do my best editing after I click on the submit button.

Offline

#3 2011-01-12 10:40:42

bmwg
Member
Registered: 2010-04-06
Posts: 39

Re: Search doesn't return any results (even though it should)

Thanks for your quick reply!
I found out, that it actually works, but only with live articles. But I want to include the fixed articles too. Is there any way to do that?

Offline

#4 2011-01-12 11:01:20

jsoo
Plugin Author
From: NC, USA
Registered: 2004-11-15
Posts: 1,793
Website

Re: Search doesn't return any results (even though it should)

article has a searchsticky attribute.


Code is topiary

Offline

#5 2011-01-17 16:28:20

bmwg
Member
Registered: 2010-04-06
Posts: 39

Re: Search doesn't return any results (even though it should)

thanks!

Offline

Board footer

Powered by FluxBB