Gossamer Forum
Home : Products : Gossamer Links : Discussions :

search result witout ?query=

Quote Reply
search result witout ?query=
Is there a way that when user search in the site the URL will not look like this
www.mysite.com/search.cgi?query=aaa
that it will look like this
www.mysite.com/search/aaa

Now the form action move to the first URL, is there a wat to change it?
Quote Reply
Re: [nir] search result witout ?query= In reply to
Hi,

As far as I know, there is no way to do this.

You can make it so you use /search/the_query to work when you link to a "top searched" query ... but I don't think you can change the URL when they search, so it goes to a URL like that

Cheers

Andy (mod)
andy@ultranerds.co.uk
Want to give me something back for my help? Please see my Amazon Wish List
GLinks ULTRA Package | GLinks ULTRA Package PRO
Links SQL Plugins | Website Design and SEO | UltraNerds | ULTRAGLobals Plugin | Pre-Made Template Sets | FREE GLinks Plugins!
Quote Reply
Re: [nir] search result witout ?query= In reply to
Hi.

Use a Mod_Rewrite

Try

.htaccess

Options +FollowSymLinks -MultiViews

RewriteEngine On

RewriteRule ^search/([^/]+)$ /search.cgi?query=$1 [QSA,L]


use: http://www.dominio.tld/search/keyword

you can use any mane im ^search


Quote Reply
Re: [Janio] search result witout ?query= In reply to
Yeah, that will kinda work - but I think he was asking if you could change it so the form that submitted looked like:

search/something

...even you actually submit the "search" form :)

Cheers

Andy (mod)
andy@ultranerds.co.uk
Want to give me something back for my help? Please see my Amazon Wish List
GLinks ULTRA Package | GLinks ULTRA Package PRO
Links SQL Plugins | Website Design and SEO | UltraNerds | ULTRAGLobals Plugin | Pre-Made Template Sets | FREE GLinks Plugins!
Quote Reply
Re: [Andy] search result witout ?query= In reply to
Yes, it has to change the search form to
<form action="<%config.db_cgi_url%>/search/">
Quote Reply
Re: [Janio] search result witout ?query= In reply to
That wouldn't work :)

It would format the URLs as:

/search/?query=foo bar

Wink

Cheers

Andy (mod)
andy@ultranerds.co.uk
Want to give me something back for my help? Please see my Amazon Wish List
GLinks ULTRA Package | GLinks ULTRA Package PRO
Links SQL Plugins | Website Design and SEO | UltraNerds | ULTRAGLobals Plugin | Pre-Made Template Sets | FREE GLinks Plugins!
Quote Reply
Re: [Andy] search result witout ?query= In reply to
hummm

only works for a direct link.. Frown
Quote Reply
Re: [Janio] search result witout ?query= In reply to
Yup, which is why I said it wasn't really possible Smile

It could be done - by adding a plugin that would convert the values that get passed in, into the new format - and then doing a 301 redirect, but its a lot of work just for that =)

Cheers

Andy (mod)
andy@ultranerds.co.uk
Want to give me something back for my help? Please see my Amazon Wish List
GLinks ULTRA Package | GLinks ULTRA Package PRO
Links SQL Plugins | Website Design and SEO | UltraNerds | ULTRAGLobals Plugin | Pre-Made Template Sets | FREE GLinks Plugins!