Return-Path: Delivered-To: apmail-httpd-users-archive@www.apache.org Received: (qmail 94212 invoked from network); 15 Jun 2010 13:20:07 -0000 Received: from unknown (HELO mail.apache.org) (140.211.11.3) by 140.211.11.9 with SMTP; 15 Jun 2010 13:20:07 -0000 Received: (qmail 48265 invoked by uid 500); 15 Jun 2010 13:20:04 -0000 Delivered-To: apmail-httpd-users-archive@httpd.apache.org Received: (qmail 48121 invoked by uid 500); 15 Jun 2010 13:20:02 -0000 Mailing-List: contact users-help@httpd.apache.org; run by ezmlm Precedence: bulk Reply-To: users@httpd.apache.org list-help: list-unsubscribe: List-Post: List-Id: Delivered-To: mailing list users@httpd.apache.org Received: (qmail 48113 invoked by uid 99); 15 Jun 2010 13:20:01 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 15 Jun 2010 13:20:01 +0000 X-ASF-Spam-Status: No, hits=3.1 required=10.0 tests=FREEMAIL_FROM,RCVD_IN_DNSWL_NONE,SPF_PASS,T_TO_NO_BRKTS_FREEMAIL,URI_OBFU_WWW X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of covener@gmail.com designates 209.85.216.173 as permitted sender) Received: from [209.85.216.173] (HELO mail-qy0-f173.google.com) (209.85.216.173) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 15 Jun 2010 13:19:55 +0000 Received: by qyk32 with SMTP id 32so187595qyk.18 for ; Tue, 15 Jun 2010 06:19:34 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:received:in-reply-to :references:date:message-id:subject:from:to:content-type :content-transfer-encoding; bh=/YiAr/5Pjh/5wK3RvSzJXDQJRJ2dXIUDoSS/n0J+3fQ=; b=Qxm5SdSN3l+aXxQNFJSPWEZRnYigob582uWnVEJK4HGeZou9f5u6DTrP1JQejrdy8d 8Ik+H6+3ZDmfPn71lQ+T4dKhnZXKZTysp5axL5qzsekZwWEVgoIkVsXb4d+dyfKcdgCv EnPh3UFE4dCKdW+qCKdMYxBVj2Jp67CykMx5M= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type:content-transfer-encoding; b=VUk+PT4tiDjLVhnmkTIKy+REtBVy4QUZZwsf9Qs4cpgoxwNms8Fk7VyuMeuINu+k4A Nm58yXAdJgfPazrPozM/yj00zE9B89q/ls7N5G8mQUXA+GFtR2OIc8eluWUKwQmT1Ptw FvNLsAwUECFYQX07z34+PqVEl57aGrtC2jDPE= MIME-Version: 1.0 Received: by 10.224.96.229 with SMTP id i37mr3176829qan.270.1276607973850; Tue, 15 Jun 2010 06:19:33 -0700 (PDT) Received: by 10.229.232.143 with HTTP; Tue, 15 Jun 2010 06:19:33 -0700 (PDT) In-Reply-To: References: Date: Tue, 15 Jun 2010 09:19:33 -0400 Message-ID: From: Eric Covener To: users@httpd.apache.org Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable X-Virus-Checked: Checked by ClamAV on apache.org Subject: Re: [users@httpd] rewrite rule tutorial on ask apache I could not understand syntax On Tue, Jun 15, 2010 at 8:42 AM, Tapas Mishra wrot= e: > http://http://www.askapache.com/htaccess/crazy-advanced-mod_rewrite-tutor= ial.html > > =A0is a link to a tutorial which mentions following use of ReWriteRule is= wrong. > > RewriteEngine On > RewriteBase / > > RewriteCond %{HTTP_HOST} !^www\.askapache\.com$ [NC] > RewriteRule .+ http://www.askapache.com%{REQUEST_URI} > > I could not understand what is the mistake in the above rule? > Can some one point what is the error which the tutorial is trying to tell= . Who can guess if that silly page meant either of these subtle issues with the recipe: *) ".+" in .htaccess won't match a request for "/", but I doubt that's the operative part of the exercise. *) You Should not redirect if HTTP_HOST is empty, for HTTP/1.0 clients, or you might loop. --=20 Eric Covener covener@gmail.com --------------------------------------------------------------------- The official User-To-User support forum of the Apache HTTP Server Project. See for more info. To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org " from the digest: users-digest-unsubscribe@httpd.apache.org For additional commands, e-mail: users-help@httpd.apache.org