httpd-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "DvDmanDT" <dvdma...@telia.com>
Subject Re: [users@httpd] aliasmatching, $1, $2, etc. need explanation please
Date Fri, 08 Aug 2003 14:26:57 GMT
$1 is the contents of the first ( )... So yes, you were right about what $1
was, and there is no $2 as there is only one ( )...
// DvDmanDT
MSN: dvdmandt@hotmail.com
Mail: dvdmandt@telia.com
----- Original Message ----- 
From: "Chris Edwards" <chris.edwards@obinet.com>
To: <users@httpd.apache.org>
Sent: Friday, August 08, 2003 4:22 PM
Subject: [users@httpd] aliasmatching, $1, $2, etc. need explanation please


> Hi
>
> I'm trying to figure out what the $1,  $2, etc.. mean in the following:
>
> ScriptAliasMatch ^/~([^/]*)/cgi-bin/(.*) /home/$1/cgi-bin/$2
>
> With a request to http://example.com/~user/cgi-bin/script.cgi
>
> Are they variables which contain a match against the regex?
>
> Like $1 = user, $2 = script.cgi ?
>
> I have an AliasMatch, ^/(.*) /some/place/index.php$1
>
> with a request to http://example.com/home/main.html?this=something
>
> What is stored in $1?
>
> I'm thinking /home/main.html?this=something
>
> Am I correct?
>
> Is there a $2 variable for this match also?  If so, what would it be.
>
> Thanks.
>
> -- 
> Chris Edwards
> Web Application Developer
> Outer Banks Internet, Inc.
> 252-441-6698
> chris.edwards@obinet.com
> http://www.OuterBanksInternet.com
>
>
> ---------------------------------------------------------------------
> The official User-To-User support forum of the Apache HTTP Server Project.
> See <URL:http://httpd.apache.org/userslist.html> 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 <URL:http://httpd.apache.org/userslist.html> 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


Mime
View raw message