perl-modperl mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Chris Schults" <cschu...@grist.org>
Subject The case of the disappearing plus sign
Date Mon, 18 Dec 2006 18:45:14 GMT
We have a CGI script that will list all the stories tagged with a
specified keyword. For example, if you wanted to see all stories tagged
with "pollution":

/cgi-bin/script.pl?query=gristkeywords=pollution

For a more user-friendly URL, we setup the following rewrite rule in an
.htaccess file that is located in the directory "tag".

RewriteEngine on
RewriteRule ^([^/\.]+)?$ /cgi-bin/script.pl?query=gristkeywords=$1 [L]

This allows a user to use this instead: /tag/pollution

This is all working fine except when we use multiple keywords with "+"
as the separator, such as: /tag/water+pollution

It appears that the "+" is getting stripped out at some point as the
script is returning results for "water pollution" instead of
"water+pollution". Is it possible that Apache is the culprit or should
we be looking more closely at our script or rewrite rule?

Thanks,

Chris

--------------------------

Chris Schults
Web Production Manager
Grist Magazine
710 Second Avenue, Suite 860
Seattle, WA  98104
Phone: 206-876-2020, ext. 204
Fax: 253-423-6487
<http://www.grist.org>

To sign up for Grist by email, the world's top environmental news served
up with a sense of humor, click here <http://www.grist.org/signup/> or
send a blank email message to <daily-grist-subscribe@lists.grist.org> 

Mime
View raw message