LinuxQuestions.org
Visit Jeremy's Blog.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 03-21-2008, 12:24 PM   #1
Chrizzieej
Member
 
Registered: Jan 2007
Location: Netherlands, The
Posts: 51

Rep: Reputation: 15
Dynamically virtualhosts under Apache


Hello folks,

Is there a way to use dynamically virtualhosts under Apache?

For example:
I've got a directory /var/www/domain.com/ and I create a subdirectory www.domain.com. Can I let Apache read /var/www/domain.com/ and automatically create www.domain.com (because a directory www.domain.com exists)?

Greetz Chrizzieej

Last edited by Chrizzieej; 03-21-2008 at 12:30 PM.
 
Old 03-21-2008, 04:46 PM   #2
trickykid
LQ Guru
 
Registered: Jan 2001
Posts: 24,149

Rep: Reputation: 269Reputation: 269Reputation: 269
It's all in mod_rewrite. Now, go read up about it. http://httpd.apache.org/docs/2.2/mod/mod_rewrite.html
 
Old 03-23-2008, 03:17 AM   #3
datopdog
Member
 
Registered: Feb 2008
Location: JHB South Africa
Distribution: Centos, Kubuntu, Cross LFS, OpenSolaris
Posts: 806

Rep: Reputation: 41
Actually there is a better way to do it using mod_vhost_alias http://httpd.apache.org/docs/2.2/mod...ost_alias.html
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Apache Virtualhosts and subdomains arew264 Linux - Networking 1 01-03-2006 08:53 AM
Apache VirtualHosts and VSFTPd critical Linux - Software 3 09-14-2005 02:12 PM
Apache VirtualHosts Problem stratisphere Linux - Newbie 4 11-27-2004 12:20 AM
VirtualHosts & apache 2.0.48 TiCkO Linux - Networking 2 07-13-2004 03:20 PM
Virtualhosts in apache. where am i going wrong. SSBN Linux - Networking 20 07-11-2003 04:02 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 11:55 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration