Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

htdocs path in linux

Tags:

html

php

lighttpd

I am working on linux server through ssh and want to know where to put html and php files (the htdocs folder) but its seems to me the servers is running lighttpd

My directory structure looks something like this.

alt text

like image 313
Shishant Avatar asked Oct 17 '09 18:10

Shishant


People also ask

Where do we find htdocs folder?

Under XAMPP root directory there is a folder called htdocs. That's where you should put your web site related stuff. For each web site you create, it's better to create a folder inside htdocs folder and then put content inside that to avoid conflicts.

Where is Apache htdocs on Ubuntu?

Popular locations for the htdocs folder are /var/www or somewhere within /srv. Save this answer.

How do I access Htdocs in my browser?

To access, download and upload files in your htdocs folder you would use File Transfer Protocol (FTP), sFTP, WebDAV or something similar. If you are working on a local server using a stack such as LAMP, MAMP, of WAMP you can simply navigate to the appropriate folder on your computer.


2 Answers

That totally depends on your server configuration so your only reliable source of information should be lighttpd's configuration file which (if installed globally) should normally be within the /etc folder (e.g. /etc/lighttpd/lighttpd.conf).

Popular locations for the htdocs folder are /var/www or somewhere within /srv.

like image 68
Horst Gutmann Avatar answered Sep 30 '22 20:09

Horst Gutmann


I would say it kind of depends on the configuration of your server.

Still, maybe something like /var/www would do, if it exists : this is the default, with many Linux distributions, for the HTTP root folder.

If it's not there, you should try to find the configuration file for Lighttpd (something like lighttpd.conf, probably somewhere under /etc) ; in that file, there should be the path for the server.document-root.
For more informations : Lighttpd - TutorialConfiguration

like image 20
Pascal MARTIN Avatar answered Sep 30 '22 20:09

Pascal MARTIN