ls -la
), file names no longer, than 256 symbols and absolutely non-secure access to non-public project folders forced me to switch to Linux Mint 17 KDE (Debian - Ubuntu fork). <?php phpinfo();
inside ( http://site1/foo.php
) - everything is OK. Any ideas?
Here is the code https://yadi.sk/d/Vi4VVho3bN3Ps
抱歉,我还没有评论功能,只是您可以在Linux上使用XAMPP,但是通常不建议在开发之外使用。
SOLVED. According to http://httpd.apache.org/docs/2.2/en/vhosts/
I needed Name-based Virtual Hosts (More than one web site per IP address) described here http://httpd.apache.org/docs/2.2/vhosts/name-based.html
. For this I needed to uncomment or create NameVirtualHost *:80
directive in httpd.conf
. However, here https://wiki.apache.org/httpd/DistrosDefaultLayout#Debian.2C_Ubuntu_.28Apache_httpd_2.x.29:
is stated that debian based linux distros use two config files ( /etc/apache2/apache2.conf
and /etc/apache2/ports.conf
) instead of classic httpd.conf
one. Neither of my two config files had NameVirtualHost *:80
directive. Therefore, I created it in /etc/apache2/apache2.conf
. This didn't work even after checking access rights to folders and files in my user folder (644 instead of 755 also OK) and sudo a2dissite site1.conf
, sudo a2ensite site1.conf
, service apache2 reload
. I made PC reboot - and voila! - I see my virtual hosts in browser.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.