Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#1 2007-05-20 15:11:59

re3
New Member
Registered: 2007-05-20
Posts: 1

How do I set up Search Section?

Hi,

Do you know how can I set up Search Section?
So my search results goes in /search/

10x

Offline

#2 2007-05-20 15:36:04

wet
Developer Emeritus
From: Schoerfling, Austria
Registered: 2005-06-06
Posts: 3,330
Website Mastodon

Re: How do I set up Search Section?

Ask Justin.

Last edited by wet (2007-05-20 15:36:16)

Offline

#3 2007-05-21 20:16:17

alexandra
Member
From: Cologne, Germany
Registered: 2004-04-02
Posts: 1,370

Re: How do I set up Search Section?

Justins tut is a bit complicated… you do not need to perform a db dump and such stuff. it is much easier:

put this on your front page:

<form action="/search/" method="get" class="myClass">
<input type="text" name="q" value="" size="16" /></form>

it directs search results to section search. use the tags for searches as justin explains.

If you are german, read this

Last edited by alexandra (2007-05-21 20:19:36)

Offline

#4 2007-05-21 20:23:47

els
Moderator
From: The Netherlands
Registered: 2004-06-06
Posts: 7,458

Re: How do I set up Search Section?

Or ask zem :)

Offline

#5 2007-05-21 20:32:36

jstubbs
Member
From: Hong Kong
Registered: 2004-12-13
Posts: 2,395
Website

Re: How do I set up Search Section?

Its easy:

1. Setup a section called “search”
2. Create a form called “search” or whatever you want. I have this in my form:
<div id=“searchbar”>
<txp:search_input section=“search” label=”“ button=“Search” size=“12” />
</div>
3. Output the form in the page wherever you want it to appear, like so:
<!— search —>
<txp:output_form form=“search” />

Et voila!

Offline

Board footer

Powered by FluxBB