I don't know about lamp and phpmyadmin but you can install an apache server and it's just as you described in Windows. The root directory in the latest version is now "/var/www/html" instead of "/var/www" and the "it works" page is "/var/www/html/index.html" .
You can directly edit the code in the "index.html" file (easiest) or you can specify another file to use by editing the conf file "/etc/apache2/apache2.conf" .
sudo apt-get install apache2 php5 libapache2-mod-php5
sudo service apache2 restart
To reload apache after changing the "index.html" file, you can run the following command:
sudo service apache2 graceful
To access the page from a web browser, go to http://localhost
, http://127.0.0.1
, or use the ip statically assigned or otherwise provided by DHCP.
I recommend visiting the default index.html page before changing it as there is now some useful information beyond the typical "it works".
For even more info, visit the apache2 manual with the following command.
man apache2
and
/usr/share/doc/apache2/README.Debian.gz
You do have to unzip this file.
UPDATE
In the most recent version of apache2 provided by ubuntu and unlike windows "the default document root is [now] located [in the] /var/www/html" archive (folder) instead of /var/www archive (folder) like it used to be. You can make virtual hosts in /var/www if you want to but if you "just want to access a folder or new website you created with a browser" you need to drop them in the /var/www/html/* directory instead of /var/www/ .
If you have another site (firstsite.html), drop it in "/var/www/html/firstsite.html"
To access this page from your browser, go navigate to the URL "http://127.0.0.1/firstsite.html
" just as you would have done from windows.
sudo service apache2 start
. – enedil Aug 10 '14 at 22:25