You are not logged in.
I am trying to set open_basedir in php.ini.
I fallow wiki page: https://wiki.archlinux.org/index.php/LAMP
in my /etc/php/php.ini
open_basedir = /srv/http/:/home/:/tmp/:/usr/share/pear/:/home/mylinuxusername/public_html
I have test.php file in ~/public_html
how can I access that file in browser? (sorry! my question may be very stupid for you)
I do
http://localhost/home/mylinuxusername/public_html/test.php
I get "Object not Found"
If I use default dir putting test.php file in /srv/http and go to
http://localhost/test.php
it is ok.
Last edited by mshan (2014-11-04 04:49:43)
Amazing !
Offline
Try changing the DocumentRoot and the <Directory> paths to /home/mylinuxusername/public_html, in the apache site configuration file.
Offline
If you enabled userdir extension, as mentioned on the wiki, then you need to use:
http://localhost/~mylinuxusername/test.php
UPDATE {
Also:
chmod -R 755 ~/public_html
Could help.
ALSO: Try adding /home to your basedir
}
Last edited by aditya3098 (2014-10-21 15:38:59)
Offline
it's shame.
I didn't do
$ chmod o+x ~
$ chmod o+x ~/public_html
now I did and get it ok.
Amazing !
Offline