M BUZZ CRAZE NEWS
// general

Apache server document root in linux

By Emma Johnson

I have to find code of websites from customer's Linux Ubuntu server . I have checked their default-document root that is .

/var/www/localhost/htdocs

I just found there many html files (e.g index.html.en , index.html.fr,index.html.ce, index.html.ft) but not whole website code like php script.

These files are located in /etc/apache2/

httpd.conf
magic
modules.d
ssl
vhosts.d

Where would the php script files be? Or could you suggest me any way for me to find them. Thanks

2 Answers

Does a2query -s show something? It should list enabled sites. Usually the site-config should be under /etc/apache2/sites-available/site.conf, symlinked to /etc/apache2/sites-enabled/site.conf, if the site is enabled.

Maybe the function phpinfo(); helps you

<?php
phpinfo();
?>

It sould list information about the webserver. In the section Apache environment the document root should be listed

5

first of all there was file name as httpd.conf where custom directory was defined like

 etc /.../vhosts.d/*conf

vhosts.d files had 3 conf files . one of them was related to my code . server-name and rewriterule were defined there. like

 /virtualhosts/aalm/ecash3/....www/

i got target files in www.

Your Answer

Sign up or log in

Sign up using Google Sign up using Facebook Sign up using Email and Password

Post as a guest

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy