Page 1 of 1

Virtual Hosting Adding multiple domain names in XAMPP questi

PostPosted: 26. April 2009 01:08
by tedge
:) Virtual Hosting Adding multiple domain names in XAMPP question ???
The setup apache friends xampp (basipaket) ver 1.7.0
Apache 2.2.11
N0-IP DUC v2.2.1
Windows xp professional with service pack 2.

My web hosting with cable ntl use dynamic ip address DHCP.
A few attempts to add an extra domain could not be seen outside my local host.
My first domain name works fine as a local host and externally can be seen anywhere on the internet. The second domain name is working but brings up the same index file
as the first domain name.

I am using XAMPP and wish to use free domain names supplied by http://www.no-ip.com/
both urls g6xfu.myftp.org and systems-edge.myftp.org are ticked with a yellow simily icon. 8) 8)

Editing the
apache 2 httpd-vhost.conf and httpd.conf did not work :cry:
-------------------------------------------------------------------------------------------------------
#
# Virtual Hosts
# c:/xampp/apache/extra/httpd-vhost.conf:
# unused # comments removed for readablity
#
# using a ddns free domain from no-ip.com http://xampp/htdocs/myftp.org
#
# No-ip DUC loaded
#
# windows xp professional with service pack 2
#
# default xampp install works 100% with a standard install with both localhost & remote internet connection
# the email address is on different host
# testing the following settings.
# required to work with both local PC and remote internet access.
#
#
<VirtualHost *:80>
DocumentRoot c:/xampp/htdocs
ServerName localhost
ServerAdmin admin@localhost

# ErrorLog logs/localhost-error_log.log
# CustomLog logs/localhost-error_log.log common
</VirtualHost>

<VirtualHost *:80>
ServerAdmin nospam@systems-edge.co.uk
DocumentRoot c:/xampp/htdocs/g6xfu
ServerName g6xfu.myftp.org
ServerAlias http://g6xfu.myftp.org
# ErrorLog logs/g6xfu/logs
# CustomLog logs/g6xfu/logs.log common
</VirtualHost>

<VirtualHost *:80>
ServerAdmin nospam@systems-edge.co.uk
DocumentRoot c:/xampp/htdocs/systems-edge
ServerName systems-edge.myftp.org
ServerAlias http://systems-edge.myftp.org
# ErrorLog logs/g6xfu/logs
# CustomLog logs/g6xfu/logs.log common
</VirtualHost>
#
# \ changed to / to comply with linux
#
# paths for my site c:/xampp/htdocs (default localhost with my index.html)
# c:/xampp/htdocs/g6xfu/index.html (my start page for http://g6xfu.myftp.org)
# c:/xampp/htdocs/systems-edge/index.html
# (my start page for http://systems-edge.myftp.org)
# C:/xampp\htdocs/systems-edge/logs (folder for error logs)
# the script in c:/xampp/apache/conf/httpd.conf needs enabling remove
# the hash prompt in the following Virtual hosts.
# Virtual hosts Include c:/xampp/apache/extra/httpd-vhost.conf
#
#end of script
------------------------------------------------------------------------------------------------------
The above settings failed
(1) could not launch the apache control panel
[tick] Apache (Running not displayed)
(2) localhost not working
(3) clicking on the xampp_start icon in the xampp folder came up with a error window problem in line 500 or 501 httpd.cnf
---------------------------------------------------------------------------
Does anyone have a working setup under windows apache xampp.
For addon domains that work with localhost and remote internet access. :D

Re: Virtual Hosting Adding multiple domain names in XAMPP questi

PostPosted: 06. May 2009 10:10
by tedge
Ref: http://g6xfu.myftp.org main url
with new [i]addon domain name
http://systems-edge.myftp.org

At long last the the add on domain is now working with Windows XP apache xampp

here is the new working httpd-vhosts file

c:\xampp\apache\conf\extra

httpd-vhosts file
----------------------------------------------------------------------------------------------------
#
# Virtual Hosts
#
# If you want to maintain multiple domains/hostnames on your
# machine you can setup VirtualHost containers for them. Most configurations
# use only name-based virtual hosts so the server doesn't need to worry about
# IP addresses. This is indicated by the asterisks in the directives below.
#
# Please see the documentation at
# <URL:http://httpd.apache.org/docs/2.2/vhosts/>
# for further details before you try to setup virtual hosts.
#
# You may use the command line option '-S' to verify your virtual host
# configuration.

#
# Use name-based virtual hosting.
#
NameVirtualHost *:80

#
# VirtualHost example:
# Almost any Apache directive may go into a VirtualHost container.
# The first VirtualHost section is used for all requests that do not
# match a ServerName or ServerAlias in any <VirtualHost> block.
#
<VirtualHost *:80>
ServerAdmin your-email@address.co.uk
DocumentRoot c:\xampp\htdocs
ServerName g6xfu.myftp.org
ErrorLog c:\xampp\htdocs\g6xfu.myftp.org.com-error_log
CustomLog c:\xampp\htdocs\g6xfu.myftp.org-access_log common
</VirtualHost>
#
<VirtualHost *:80>
ServerAdmin your-email@address.co.uk

DocumentRoot c:\xampp\htdocs\systems-edge
ServerName systems-edge.myftp.org
ErrorLog c:\xampp\htdocs\systems-edge.myftp.org.com-error_log
CustomLog c:\xampp\htdocs\systems-edge.myftp.org-access_log common
</VirtualHost>
##<VirtualHost *:80>
## ServerAdmin webmaster@dummy-host.example.com
## DocumentRoot /www/docs/dummy-host.example.com
## ServerName dummy-host.example.com
## ServerAlias http://www.dummy-host.example.com
## ErrorLog @rel_logfiledir@/dummy-host.ex
## CustomLog @rel_logfiledir@/dummy-host.example.com-access_log common
##</VirtualHost>

##<VirtualHost *:80>
## ServerAdmin webmaster@dummy-host2.example.com
## DocumentRoot /www/docs/dummy-host2.example.com
## ServerName dummy-host2.example.com
## ErrorLog @rel_logfiledir@/dummy-host2.example.com-error_log
## CustomLog @rel_logfiledir@/dummy-host2.example.com-access_log common
##</VirtualHost>
----------------------------------------------

The httpd.conf is left at the default setting

regards Tony Edge
http://www.systems-edge.co.uk