Getting VHosts working with EasyPHP
Asked Answered
D

1

7

So I've been trying to setup vhosts on my new Windows 10 Installation with EasyPHP Devserver 16.1.

I've modified etc/vhosts to include my new domain (mysite.local), which works, but still points to the default easyphp directory. So I modified httpd-vhosts.conf to point that domain to my new directory:

<VirtualHost *:80>
    DocumentRoot "C:\Program Files (x86)\EasyPHP-Devserver-16.1\eds-www"
    ServerName localhost
</VirtualHost>
<VirtualHost *:80>
    DocumentRoot "C:\Users\Chris\Documents\Web_Development\mysite"
    ServerName mysite.local
</VirtualHost>

However when I start the server, it wipes this file so that it's just blank, and my domain still points to the default easyphp directory. What would be causing this/how can I fix it?

I've tried putting the vhosts directly into httpd.conf, however that doesn't change anything, still my new domain points to the default folder.

I'm really not getting anywhere with this and I absolutely need vhosts working so I can work on multiple sites.

I could go back to Xampp, which is what I used on Mac OS, however I had an ongoing issue with that where PHPExcel didn't export properly so I'd like to try with Easy PHP

Dabster answered 16/3, 2016 at 1:26 Comment(1)
Is there a Dev Server 17 answer to this process.Selfpossessed
N
5

At the end of your httpd.conf add : Include conf/whateveryouwant.conf And put your virtual hosts in this file

Nomarchy answered 2/4, 2016 at 8:48 Comment(4)
Thanks! Odd that the default file wouldn't work, but including my own was fine. I've got 4 local domains running just fine now!Dabster
This doesn't appear to be working for me, no matter what file I use, including conf/httpd-vhosts.conf, conf/extra/httpd-vhosts.conf, or conf/virtuals.conf. Any ideas?Whereof
Got it working. Changed <VirtualHost *:80> to <VirtualHost 127.0.0.1>.Whereof
This technique still works in 2019 for Dev Server 17. ThanksSelfpossessed

© 2022 - 2024 — McMap. All rights reserved.