0

Mkdir and fopen works in the web hosting service but does not work in my lamp in opensuse tumbleweed linux.

how to give apache or php permission to make directory or a file?

i tried this How to give apache permission to write to home directory? but the www-data is invalid user in opensuse tumbleweed ``

nothingn
  • 1
  • 2

1 Answers1

1

I'm no Linux expert, and I bet there are better answers then mine. But maybe this can help you.

On a laptop that is for development you could do chmod -R 777 /var/www/html/your_project_dir every user can now make and or delete files in that project. (Never do this outside a development environment)

You can also check your apache2.conf file on most linux systems it can be found in /etc/apache2/envvars. In that file you can see as what user apache is running. And then try the steps from the link you posted again.

Baracuda078
  • 677
  • 1
  • 5
  • 10