I would like follows the examples shown in this book.
I remember that phase many moons ago. example.com will work but change to something yours asap, like www.mysite.local.
16:39 16/05/2015# ::1 localhost
#
#127.0.0.1 http://www.example.com # for browser access
127.0.0.1 www.example.com # for browser access
127.0.0.1 mail.example.com # for mail access
127.0.0.1 example.com # for mercury mail server
Get rid of the debris in red, whatever that is.
When I tried this, www.example.com arrived at the Xampp front page, as it should. No restart necessary (Win7).
If yours doesn't...I don't know. You are editing the file as administrator?
Now you have to configure the Xampp apache server so it knows what to do when presented with www.example.com: which files to serve up for that domain, using a virtualhost.
While I am the first to tell people to google it, I do remember some pain in getting this to work...
You can use an alias or virtualhost. I found an alias worked up until I started to use URI remapping then had to man up to get a virtualhost working so better to do it now.
Make sure you restart apache after every change so you know when you have broken something.
Enable SSL:
Code:
C:\xampp5680-portable\apache\conf\httpd.conf
LoadModule ssl_module modules/mod_ssl.so
And this is my C:\xampp5680-portable\apache\conf\extra\httpd-vhosts.conf
with some names changed to protect the innocent.
Code:
##for all non-matching
<VirtualHost *:80>
ServerAdmin [email protected]
DocumentRoot "/xampp5680-portable/htdocs"
ServerName localhost
</VirtualHost>
## for all non-matching: SSL
<VirtualHost *:443>
ServerAdmin [email protected]
DocumentRoot "/xampp5680-portable/htdocs"
ServerName localhost
SSLEngine on
SSLCertificateFile conf/ssl.crt/server.crt
SSLCertificateKeyFile conf/ssl.key/server.key
</VirtualHost>
<VirtualHost *:80>
ServerName www.mysite.local
ServerAlias www.mysite.local
DocumentRoot "D:/My Documents/Business/Mysite/spanish website/home/public_html"
ErrorLog "logs/vhost-error.log"
CustomLog "logs/vhost-access.log" combined
<Directory "D:/My Documents/Business/Mysite/spanish website/home/public_html">
AllowOverride All
Require all granted
</Directory>
</VirtualHost>
<VirtualHost *:443>
ServerName www.mysite.local
ServerAlias www.mysite.local
SSLEngine on
SSLCertificateFile conf/ssl.crt/server.crt
SSLCertificateKeyFile conf/ssl.key/server.key
DocumentRoot "D:/My Documents/Business/Mysite/spanish website/home/public_html"
ErrorLog "logs/vhost-error.log"
CustomLog "logs/vhost-access.log" combined
<Directory "D:/My Documents/Business/Mysite/spanish website/home/public_html">
AllowOverride All
Require all granted
</Directory>
</VirtualHost>
I've probably forgotten something.
As for the mail servers etc. forget them for the moment. Once you have smtp settings in the shop admin you can use real addresses and the emails will work.
Bookmarks