phphtmlapache

What is the difference between the 'www' folder and 'htdocs' folder?


After I installed Apache on my web server there was created a folder called www. Whatever files like HTML and PHP files I put there it will be on my website.

However, I followed one of the tutorial on YouTube and also even my own XAMPP folder has a htdocs folder which is the same as the www folder. When I put a file inside I can see it if I type its name after localhost. Is there any difference between these two? How have we defined these directories as a container of our files?


Solution

  • There is no difference. You can configure Apache httpd to use any folder with appropriate permissions as the root server directory. www is just a conventional directory to use.