virtual hosts on xampp 7.0.3

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

virtual hosts on xampp 7.0.3

Postby patratel » 28. February 2016 10:28

Hi,
I've upgraded my pc to windows 10 (clean install) and i've installed xampp 7.0.3, php is working, but virtual-hosts are not.
I've put in hosts file my site:
"127.0.0.1 localhost
127.0.0.1 cmtr"

I put also in httpd-vhosts.conf:

<Directory D:/sites>
Require all granted
</Directory>

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

<VirtualHost *:80>
DocumentRoot "D:/sites/cmtr"
ServerName cmtr
</VirtualHost>

Can someone help me, what I've missed, or what I'm doing wrong?

Thanks,
patratel
patratel
 
Posts: 8
Joined: 07. June 2013 15:22
Operating System: win xp

Re: virtual hosts on xampp 7.0.3

Postby Nobbie » 28. February 2016 10:47

We need more information abou that.

What exactly is happening, what exactly do you enter in the browser, are you running the browser on the same PC as Xampp and please provide all error messages completely.

P.S.: Did you "un-uncomment" (i.e. remove the # in the beginning) the corresponding include for httpd-vhosts.conf in httpd.conf? It is NOT sufficient only to change httpd-vhosts.conf
Nobbie
 
Posts: 8775
Joined: 09. March 2008 13:04

Re: virtual hosts on xampp 7.0.3

Postby patratel » 28. February 2016 11:13

I am on same PC with xampp.
______________
When I enter in browser "//http://localhost/test.php", i get the phpinfo().
When I enter localhost/cmtr, I got Error 404:
"Object not found!
The requested URL was not found on this server. If you entered the URL manually please check your spelling and try again.
If you think this is a server error, please contact the webmaster.
Error 404
localhost
Apache/2.4.18 (Win32) OpenSSL/1.0.2e PHP/7.0.3"
_____________
In httpd.conf, the vhosts where already un-commented:

# Virtual hosts
Include conf/extra/httpd-vhosts.conf
_____________
I remember that some time ago, I had to modify the grants from
"Order Deny,Allow
Allow from all"
to
"Require all granted"

Maybe is something like this, or I'm missing something:(
I've tried to put a printscreen with phpinfo and one with Error 404, but I don't know how to attach a file :)

Thanks
patratel
 
Posts: 8
Joined: 07. June 2013 15:22
Operating System: win xp

Re: virtual hosts on xampp 7.0.3

Postby Nobbie » 28. February 2016 11:36

patratel wrote:When I enter localhost/cmtr, I got Error 404:
"Object not found!
The requested URL was not found on this server. If you entered the URL manually please check your spelling and try again.
If you think this is a server error, please contact the webmaster.
Error 404
localhost
Apache/2.4.18 (Win32) OpenSSL/1.0.2e PHP/7.0.3"


Yes of course, you have a wrong understanding of VirtualHosts. in order to call http://localhost/cmtr, you must create a folder "cmtr" in the htdocs folder c:/xampp/htdocs. But if you create a VirtualHost "cmtr" instead, you MUST NOT enter http://localhost/cmtr for this VirtualHost, instead you must enter http://cmtr only (without localhost).
Nobbie
 
Posts: 8775
Joined: 09. March 2008 13:04

Re: virtual hosts on xampp 7.0.3

Postby patratel » 28. February 2016 12:07

Yes, you got wright, but help me with an other problem:
I got a rss reader, and I got this message:
"MM_XSLTransform error.
The server could not perform the XSL transformation because an XSLT processor for PHP could not be found. Contact your server administrator and ask them to install an XSLT processor for PHP."
Doesn't php 7 got XSLT support, or what?
Better I must go back to xampp 5?
I un-commented extension=php_xsl.dll in php.ini
patratel
 
Posts: 8
Joined: 07. June 2013 15:22
Operating System: win xp

Re: virtual hosts on xampp 7.0.3

Postby Nobbie » 28. February 2016 12:14

I dont know anything about the PHP XSLT processor.
Nobbie
 
Posts: 8775
Joined: 09. March 2008 13:04

Re: virtual hosts on xampp 7.0.3

Postby patratel » 28. February 2016 12:17

OK, thanks for your help.
patratel
 
Posts: 8
Joined: 07. June 2013 15:22
Operating System: win xp

Re: virtual hosts on xampp 7.0.3

Postby patratel » 28. February 2016 12:38

It worked, I went back to xampp 5.6 and it works now.
patratel
 
Posts: 8
Joined: 07. June 2013 15:22
Operating System: win xp


Return to XAMPP for Windows

Who is online

Users browsing this forum: No registered users and 70 guests