[wp-hackers] Removing ?= from searches

Robert Deaton false.hopes at gmail.com
Sun Nov 28 02:25:28 UTC 2004


Alex, that looks about right, but you messed up a tiny bit with the syntax :P

header('Location: ' . get_sesttings('siteurl') . '/search/' .
urlencode(stripslashes($_POST['s'])));
die();


On Sat, 27 Nov 2004 19:01:43 -0700, Alex King <alex at alexking.org> wrote:
> Why not do a POST from the search form then redirect to the URL as you
> want it?
> 
> I think it would be something like this...
> 
> header("Location:
> ".get_settings('siteurl')."/
> search/".urlencode(stripslashes($_POST["s"))));
> die();
> 
> --Alex
> 
> http://www.alexking.org/
> 
> 
> 
> 
> On Nov 27, 2004, at 6:08 PM, Rob Mientjes wrote:
> 
> > Your email address is not really giving us hope, Robert ;)
> >
> > It'd require Javascript. Shame. Not everybody has JS enabled.
> >
> >
> > On Sat, 27 Nov 2004 20:05:53 -0500, Robert Deaton
> > <false.hopes at gmail.com> wrote:
> >> Ah, well, how about a little javascript magic to pull the input from
> >> the textbox and use a text link instead of a form submit button, and
> >> have the link translate via .htaccess to a GET link, and have the
> >> search functions read it from get.
> >>
> >>
> >>
> >> On Sat, 27 Nov 2004 17:02:12 +0100, Rob Mientjes
> >> <robmientjes at gmail.com> wrote:
> >>> Indeed. Submitting a form gives you a nasty URI. Not cool. But what
> >>> exactly are the differences between GET and POST? That could maybe
> >>> shed a different light on this question.
> >>>
> >>>
> >>>
> >>>
> >>> On Sat, 27 Nov 2004 16:34:23 +0100, Mathias Bynens
> >>> <mathibus at gmail.com> wrote:
> >>>> Robert, the permalinks aren't the problem, the form itself is.
> >>>>
> >>>>
> >>>>
> >>>>
> >>>> On Sat, 27 Nov 2004 10:18:25 -0500, Robert Deaton
> >>>> <false.hopes at gmail.com> wrote:
> >>>>> You could do some .htaccess magic with mod_rewrite, but I have no
> >>>>> idea
> >>>>> how that goes, but I'm sure you could integrate it in with the
> >>>>> permalinks somehow (so it doesn't get removed every time your
> >>>>> permalinks are updated)
> >>>>>
> >>>>>
> >>>>>
> >>>>>
> >>>>> On Sat, 27 Nov 2004 13:00:22 +0100, Mathias Bynens
> >>>>> <mathibus at gmail.com> wrote:
> >>>>>> I'm afraid the only way to do something like this is through
> >>>>>> JavaScript... Or no, we could make the form action
> >>>>>> search.php?q=keyword for example, and then let it redirect to
> >>>>>> /search/keyword/.
> >>>>>>
> >>>>>> --
> >>>>>> Mathias Bynens aka MaThIbUs
> >>>>>> http://mathibus.com/
> >>>>>>
> >>>>>> On Sat, 27 Nov 2004 12:39:55 +0100, Michael Heilemann
> >>>>>>
> >>>>>>
> >>>>>> <michael at binarybonsai.com> wrote:
> >>>>>>> In an effort to do searches that look like this:
> >>>>>>> http://binarybonsai.com/search/keyword, we're trying to remove
> >>>>>>> the ?=
> >>>>>>> from the search form. If someone could point us in the right
> >>>>>>> direction,
> >>>>>>> that'd be great.
> >>>>>>>
> >>>>>>> Join the fray:
> >>>>>>> http://noscope.com/journal/2004/07/separate_search_page
> >>>>>>>
> 
> _______________________________________________
> hackers mailing list
> hackers at wordpress.org
> http://wordpress.org/mailman/listinfo/hackers_wordpress.org
> 


-- 
--Robert Deaton
http://false-hopes.com/
A proud Linux, Firefox, and WordPress user.
Linux is not an operating system, its a way of life.



More information about the hackers mailing list