Apache2, some variable with "domain name"?
Hi all!
I have a virtualhost definition with a lot ServerAlias values. I want to have a specific alias for any of this ServerAlias. Would be perfect if apache2 stores the domain name in som variable in order to use it to make a single AliasMatch instance for all ServerAlias. Something like: AliasMatch ^/webalizer /home/httpd/webalizer/$domain Have Apache2 anything like $domain var? Thanks!! -- Marc -- To UNSUBSCRIBE, email to debian-isp-REQUEST@lists.debian.org with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org Archive: n2see5163b51004090238qd3758a4fp2d27233616adebf3@ma il.gmail.com">http://lists.debian.org/n2see5163b51004090238qd3758a4fp2d27233616adebf3@ma il.gmail.com |
Apache2, some variable with "domain name"?
On 9 April 2010 11:38, Marc Aymerich <glicerinu@gmail.com> wrote:
Something like: AliasMatch ^/webalizer /home/httpd/webalizer/$domain Have Apache2 anything like $domain var? Maybe with this http://httpd.apache.org/docs/2.2/mod/mod_rewrite.html#rewritecond -- * * Met vriendelijke groet, * * Serge van Ginderachter |
Apache2, some variable with "domain name"?
On Fri, Apr 9, 2010 at 2:03 PM, Serge van Ginderachter
<serge@vanginderachter.be> wrote: > > > On 9 April 2010 11:38, Marc Aymerich <glicerinu@gmail.com> wrote: >> >> Something like: >> >> AliasMatch ^/webalizer /home/httpd/webalizer/$domain >> >> >> Have Apache2 anything like $domain var? > > Maybe with this > > http://httpd.apache.org/docs/2.2/mod/mod_rewrite.html#rewritecond > Thank you Serge !, This is my solution: RewriteRule ^/webalizer[/]*(.*)$ /home/httpd/webalizer/%{SERVER_NAME}/$1 -- Marc -- To UNSUBSCRIBE, email to debian-isp-REQUEST@lists.debian.org with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org Archive: l2jee5163b51004090747sd1595398q43a7cabd0ca787bd@ma il.gmail.com">http://lists.debian.org/l2jee5163b51004090747sd1595398q43a7cabd0ca787bd@ma il.gmail.com |
| All times are GMT. The time now is 12:22 PM. |
VBulletin, Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.