Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#1 2009-02-09 16:54:01

thebombsite
Archived Plugin Author
From: Exmouth, England
Registered: 2004-08-24
Posts: 3,251
Website

Search with messy URLs

I seem to be banging my head against a brick wall with this one. I’m working on a site with messy URLs (clean aren’t available) and I would like search results to go to their own section and page template. Simple enough with clean URLs but I simply can’t get it to work with messy. The results keep going to the front-page and using it’s template. Here’s my form code:-

<form method="get" action="<txp:site_url />index.php?s=search">

Am I getting the code wrong somewhere or is this not possible?


Stuart

In a Time of Universal Deceit
Telling the Truth is Revolutionary.

Offline

#2 2009-02-09 18:09:12

Gocom
Developer Emeritus
From: Helsinki, Finland
Registered: 2006-07-14
Posts: 4,533
Website

Re: Search with messy URLs

So, the form leeds to your frontpage URL?

If so, try:

<form method="get" action="<txp:site_url />">
	<input type="hidden" name="s" value="search" />
	<input type="text" name="q" value="" />
	<button type="submit">Search</button>
</form>

Offline

Board footer

Powered by FluxBB