Once I tried to make a virtual host, and the problem was that if I make another file in /etc/apache2/sites-available/ that says ...DocumentRoot /var/www/newsiteServerName   newsite...Then save it, restart Apache, and appending /etc/hosts like this:127.0.0.1 newsiteI get the page that corresponds the DocumentRoot from /etc/apache2/sites-available/defaultThat time I left it unsolved. Now I want to do it once again and I get the same problem. Despite the fact that I use different version of Linux distro. I feel like I'm doomed.
Problem making a virtual host with Apache
configuration;apache httpd
did you enable the site using the a2ensite command? The /etc/apache2/sites-available directory lists those that you have setup but it needs to be in /etc/apache2/sites-enabled to be picked up when you next reload the apache2 configuration.