Return-Path: Delivered-To: apmail-httpd-users-archive@www.apache.org Received: (qmail 13304 invoked from network); 30 Dec 2006 21:47:58 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 30 Dec 2006 21:47:58 -0000 Received: (qmail 51027 invoked by uid 500); 30 Dec 2006 21:47:53 -0000 Delivered-To: apmail-httpd-users-archive@httpd.apache.org Received: (qmail 51017 invoked by uid 500); 30 Dec 2006 21:47:53 -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 51006 invoked by uid 99); 30 Dec 2006 21:47:53 -0000 Received: from herse.apache.org (HELO herse.apache.org) (140.211.11.133) by apache.org (qpsmtpd/0.29) with ESMTP; Sat, 30 Dec 2006 13:47:53 -0800 X-ASF-Spam-Status: No, hits=-0.0 required=10.0 tests=SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (herse.apache.org: domain of mitigator@gmail.com designates 66.249.82.234 as permitted sender) Received: from [66.249.82.234] (HELO wx-out-0506.google.com) (66.249.82.234) by apache.org (qpsmtpd/0.29) with ESMTP; Sat, 30 Dec 2006 13:47:43 -0800 Received: by wx-out-0506.google.com with SMTP id t13so22800wxc for ; Sat, 30 Dec 2006 13:47:23 -0800 (PST) DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=gmail.com; h=received:message-id:date:from:to:subject:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=s8e9nNgVySQpzeh0WQsOIJs2jL1Bz48mWOn+MNwhM/43ZiGZFtSMigInTrRgMsHglvEpRuVNjuRwShM6qp91GkPKU6Ct5toXNt3ya7yKLcWw3592HRg5TK/YCt/lebQl5ev0nUUS1O9vtWs7nNptnwItV4IA2+tiMEoc5ATOHZ0= Received: by 10.90.78.1 with SMTP id a1mr12960147agb.1167515243353; Sat, 30 Dec 2006 13:47:23 -0800 (PST) Received: by 10.90.120.11 with HTTP; Sat, 30 Dec 2006 13:47:23 -0800 (PST) Message-ID: <6ff30abd0612301347ya1cbbe2u8bc92e818dc29146@mail.gmail.com> Date: Sat, 30 Dec 2006 15:47:23 -0600 From: "jamie rishaw" To: users@httpd.apache.org In-Reply-To: <4596BB70.5070301@aplus.net> MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Content-Disposition: inline References: <6ff30abd0612301109y67b336f2k92b0867dd20cc3e0@mail.gmail.com> <4596BB70.5070301@aplus.net> X-Virus-Checked: Checked by ClamAV on apache.org Subject: [users@httpd] Re: apache rewritecond spits out "http://blah.com//whatever". double slashes? didnt seem to work.. quoted backslash and otherwise. ill keep on it, thanks tho heh. On 12/30/06, Aplus Dedicated Support, Jarrod Overson wrote: > Disclaimer (and a big one at that), i have never used mod_rewrite before > but if the problem is that you continuously grab a forward slash prefix > then you can just place that outside the regex group that is to be > backreferenced, for example > > > RewriteRule ^/(.*)$ http://domain.com$1 [R=301,L] > > (or, if a forward slash is special and needs to be escaped) > > RewriteRule ^\/(.*)$ http://domain.com$1 [R=301,L] > > instead of > > RewriteRule ^(.*)$ http://domain.com$1 [R=301,L] > > > > jamie rishaw wrote: > > Guys, > > > > RewriteCond.. just added to a host to strip www off of requests > > coming to www.@ > > > > Now tho all urls are being rewritten to " > > http://host.tld//whatever". Note the double slashes after tld. > > > > While this doesnt break things /per se/, it is annoying and looks > > like a misconfigured site. Which = bad. > > > > Here's the rewrite code. What did I miss? > > > > > > ... > > RewriteEngine On > > RewriteCond %{HTTP_HOST} ^www\.domain\.com$ [NC] > > RewriteRule ^(.*)$ http://domain.com$1 [R=301,L] > > ... > > > > > > > > > > tia, > > > > jamie > > > > --------------------------------------------------------------------- > > 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 > > > > --------------------------------------------------------------------- > 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 > > -- .. i taught your boyfriend that thing you like --------------------------------------------------------------------- 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