Return-Path: Delivered-To: apmail-httpd-modules-dev-archive@locus.apache.org Received: (qmail 11214 invoked from network); 21 Aug 2007 16:36:35 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 21 Aug 2007 16:36:35 -0000 Received: (qmail 40642 invoked by uid 500); 21 Aug 2007 16:36:31 -0000 Delivered-To: apmail-httpd-modules-dev-archive@httpd.apache.org Received: (qmail 40613 invoked by uid 500); 21 Aug 2007 16:36:31 -0000 Mailing-List: contact modules-dev-help@httpd.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: modules-dev@httpd.apache.org Delivered-To: mailing list modules-dev@httpd.apache.org Received: (qmail 40604 invoked by uid 99); 21 Aug 2007 16:36:31 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 21 Aug 2007 09:36:31 -0700 X-ASF-Spam-Status: No, hits=-0.0 required=10.0 tests=SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: local policy) Received: from [216.17.105.202] (HELO phat.bettercgi.com) (216.17.105.202) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 21 Aug 2007 16:36:26 +0000 Received: from r74-192-38-125.vctrcmta01.vctatx.tl.dh.suddenlink.net ([74.192.38.125] helo=raydesk1.bettercgi.com) by phat.bettercgi.com with esmtps (TLSv1:AES256-SHA:256) (Exim 4.50) id 1INWi5-0003gn-HT for modules-dev@httpd.apache.org; Tue, 21 Aug 2007 09:36:05 -0700 Date: Tue, 21 Aug 2007 11:36:04 -0500 From: Ray Morris Subject: Re: Regex Help with Mod Rewrite To: modules-dev@httpd.apache.org References: In-Reply-To: (from soumya.sanyal@gmail.com on Tue Aug 21 11:04:58 2007) X-Mailer: Balsa 2.3.12 Message-Id: <1187714164l.14858l.6l@raydesk1.bettercgi.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii; DelSp=Yes; Format=Flowed Content-Disposition: inline Content-Transfer-Encoding: quoted-printable X-Virus-Checked: Checked by ClamAV on apache.org RewriteCond %{QUERY_STRING} ^(rain|spain|plain|,)+$ For a full explanation of what regex features are and are not available, see the first result: http://www.google.com/search?q=3Dmod_rewrite&sourceid=3Dmozilla&start=3D0&s= tart=3D0&ie=3Dutf-8&oe=3Dutf-8 -- Ray B. Morris support@bettercgi.com Strongbox - The next generation in site security: http://www.bettercgi.com/strongbox/ Throttlebox - Intelligent Bandwidth Control http://www.bettercgi.com/throttlebox/ Strongbox / Throttlebox affiliate program: http://www.bettercgi.com/affiliates/user/register.php On 08/21/2007 11:04:58 AM, Soumya Sanyal wrote: > Hello, > This might not be the most appropriate forum to field this question - > but > I'm having serious issues with the formulation of a regex for Mod > Rewrite. I > actually have a couple of questions to ask : >=20 > 1> What is particular flavor of the regex engine being used by Mod > Rewrite - > there are ever so slight variations in the different regex engines, > e.g. > linux grep vs perl grep etc. > 2> I'm having trouble formulating a good compact regex to represent > the > following problem : >=20 > I want my RewriteCond to be conditioned on the %{QUERY_STRING} to > contain > only the powerset of a group of words e.g. >=20 > Hence if my set is say {rain,spain,plain} >=20 > The RewriteCond should say yes to the following : > http://foo.bar.com/?Operation=3Drain,spain > http://foo.bar.com/?Operation=3Dplain,rain,rain > http://foo.bar.com/?Operation=3Dplain,rain,spain >=20 > But not : > http://foo.bar.com/?Operation=3Drain,spain,mainly >=20 > Help please ? >=20