Return-Path: Delivered-To: apmail-httpd-users-archive@www.apache.org Received: (qmail 12130 invoked from network); 6 Aug 2007 21:42:28 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 6 Aug 2007 21:42:28 -0000 Received: (qmail 71990 invoked by uid 500); 6 Aug 2007 21:42:17 -0000 Delivered-To: apmail-httpd-users-archive@httpd.apache.org Received: (qmail 71972 invoked by uid 500); 6 Aug 2007 21:42:17 -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 71960 invoked by uid 99); 6 Aug 2007 21:42:16 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 06 Aug 2007 14:42:16 -0700 X-ASF-Spam-Status: No, hits=-0.0 required=10.0 tests=SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of samy-delux@gmx.de designates 213.165.64.20 as permitted sender) Received: from [213.165.64.20] (HELO mail.gmx.net) (213.165.64.20) by apache.org (qpsmtpd/0.29) with SMTP; Mon, 06 Aug 2007 21:42:04 +0000 Received: (qmail invoked by alias); 06 Aug 2007 21:41:51 -0000 Received: from p549C748B.dip.t-dialin.net (EHLO 192.168.1.50) [84.156.116.139] by mail.gmx.net (mp035) with SMTP; 06 Aug 2007 23:41:51 +0200 X-Authenticated: #17392150 X-Provags-ID: V01U2FsdGVkX19UI7c7SrVUB4NH5oJMvGvamaKLNgt+PrlHmmWzgA m+vHDnsgxzqMRn Message-ID: <46B795A0.3080106@gmx.de> Date: Mon, 06 Aug 2007 23:41:52 +0200 From: Samuel Vogel User-Agent: Thunderbird 2.0.0.6 (Macintosh/20070728) MIME-Version: 1.0 To: users@httpd.apache.org References: <93ff61d20708041033j49d51479mbdca6bd3e90f6ca3@mail.gmail.com> <46B4BE83.7070209@blazestudios.com> <93ff61d20708041145k1dc2b14er991d72888df2b7b9@mail.gmail.com> <46B4D482.1050105@blazestudios.com> <46B4D900.60008@gmx.de> <46B4EF18.2070009@gmx.de> In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Y-GMX-Trusted: 0 X-Virus-Checked: Checked by ClamAV on apache.org Subject: Re: [users@httpd] Rewriting Subdomains to folders Hey, this is my best guess: RewriteEngine On RewriteCond %{HTTP_HOST} !^www\. RewriteCond %{HTTP_HOST} ^([^.]+)\.samy\.newkilu\.de RewriteRule ^/(.*)$ %1/$1 [L] But somehow this doesn't do anything... What am I doing wrong? I'm trying to rewrite "sub-sub"-domains to the appropriate folder. Regards, Samy Joshua Slive schrieb: > On 8/4/07, Samuel Vogel wrote: > >> I forgot to specify what i want/need. >> I want to specifically know how the mod_rewrite solution works, because >> I don't see how I can user the subdomain from RewriteCond in the >> RewriteRule statement... >> > > This example shows one way to do it: > http://httpd.apache.org/docs/2.2/vhosts/mass.html#homepages.rewrite > > In general, you use back-references to extract matches from > RewriteCond's. The first match would be %1, the second %2, etc. See > the RewriteRule docs. > > If you want more help, post your best guess at the correct config > along with details on what you want it to do and what it is actually > doing. > > Joshua. > > --------------------------------------------------------------------- > 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