VirtualHost in Mapped Unit? Z:/site/public_html

Problems with the Windows version of XAMPP, questions, comments, and anything related.

VirtualHost in Mapped Unit? Z:/site/public_html

Postby ride » 14. September 2006 19:29

I need some help to make this configuration.

I want to create a virtualhost accessing the files in another pc into the local network. I've tried to configure IP and other things but no success, Apache doesn't start when i use the Z:

Code: Select all
########################
# My hosts configurations

127.0.0.1       localhost.website


Code: Select all
########################
# My configurations in httpd.conf

<Directory "Z:/website/public_html">
  Options Indexes FollowSymLinks Includes ExecCGI
  AllowOverride None
  Order allow,deny
  Allow from all
</Directory>

NameVirtualHost *:80

<VirtualHost *:80>
  ServerName localhost.website
  DocumentRoot "Z:/website/public_html"
</VirtualHost>
ride
 
Posts: 3
Joined: 14. September 2006 19:13

Postby feralrath » 18. September 2006 17:36

<Directory "Z:/website/public_html">
Options Indexes FollowSymLinks Includes ExecCGI
AllowOverride None
Order allow,deny
Allow from all
</Directory>


if the Z:/ is located on another computer then you need to set up file sharing between both computers, and make sure that the 'public_html' folder is shared.

your directory should look something like

<Directory "\\computer name\public_html">

also just not

that should work, if not then the other way is a little bit harder.
feralrath
 
Posts: 5
Joined: 18. September 2006 03:37

Postby ride » 18. September 2006 19:54

The folders are shared, i've tried to use this way too "\\pc-02\site\public_html", but this not works. Could you tell me some information, or show me the way to make it in this other way you sad?
ride
 
Posts: 3
Joined: 14. September 2006 19:13

Postby Izzy » 18. September 2006 22:27

You don't use a <virtualhost> container in the httpd.conf file.
Use xampp\apache\extra\httpd-vhost.conf

I don't know why you use a strange configuration for localhost but I assume you have your reasons.
Try in host file:
Code: Select all
127.0.0.1 localhost
127.0.0.1 localhost.website



Put the httpd.conf back to the defaults (you did make a backup before editing?)

Try this in httpd-vhost.conf (change the localhost DocumentRoot to your Xampp path to htdocs directory - which should be the same as the default in your httpd.conf file).
Code: Select all
NameVirtualHost *:80

<VirtualHost *:80>
ServerName localhost
DocumentRoot "C:/your/xampp/path/htdocs"
</VirtualHost>

<VirtualHost *:80>
Servername localhost.website
DocumentRoot "Z:/website/public_html
<Directory "Z:/website/public_html">
Options Indexes FollowSymLinks Includes ExecCGI
AllowOverride None
Order allow,deny
Allow from all
</Directory>
Izzy
 
Posts: 3344
Joined: 25. April 2006 17:06

Postby ride » 21. September 2006 13:41

I've already done that.

When i use "Z:/website/public_html", Apache crashes when it starts. When i use "//PC-02/home/website/public_html", Apache starts rightly, but i got "Access Denied".
ride
 
Posts: 3
Joined: 14. September 2006 19:13


Return to XAMPP for Windows

Who is online

Users browsing this forum: No registered users and 39 guests