Jump to content


Photo

Creating Virtual Directory in Apache


  • Please log in to reply
1 reply to this topic

#1 shakim

shakim
  • Members
  • Pip
  • Newbie
  • 7 posts
  • LocationMetro Detroit,MI,USA

Posted 28 August 2006 - 05:07 PM

In IIS you were able to install the web server in windows and then create virtual directories anywhere, including a external drive.  This way the location on the external drive (directory ) would act as a webserver location.  You were able to execute scripts.  I need this setup because I would like to work on web apps at home and at work and be able and be able to just plug in my external drive and it would be part of the web server. Is there a way to do that with apache 2.0?
"Knowledge Speaks but, Wisdom Listens"
www.shumonhakim.com

#2 R_P

R_P
  • Members
  • PipPipPip
  • Advanced Member
  • 98 posts

Posted 30 August 2006 - 04:48 PM

The "Apache" term for an IIS Virtual Directory is an alias. Using apache aliases is really simple.

Search for:

# Aliases: Add here as many aliases as you need (with no limit). The format is
# Alias fakename realname

A few lines under, there might be an alias already set up. For example:

Alias /icons/ "D:/My Documents/My Webs/Apache/icons/"
    <directory "D:/My Documents/My Webs/Apache/icons" >
        Options Indexes FollowSymlinks MultiViews Includes
        AllowOverride None
        Order allow,deny
        Allow from all
  </directory>

Add as many aliases as you need, listing the path to the folder on your hard drive, using the same format as previously listed. If you are utilizing Server Side Includes (SSI) you must make sure the text “Includes” is listed or SSI will not render properly when testing in Apache.

Hope this helps.

Pro in: Win2K3S | Apache2 | PHP5 | Perl5 | MySQL | MSSQL | Firefox | Photoshop
Student of: Ubuntu6 | Java | C | VB.NET | ASP.NET
Developer: Roddzilla Webstudios, Burrson CG, DVIDSHUB, The Four Nations
Student: Georgia Tech, Georgia Tech College of Computing




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users