I want to use a custom folder for my apache web server in XAMPP and set it in the httpd.conf-file
DocumentRoot "/path/to/directory"
<Directory "/path/to/directory">
I also ensured that the user permission was set for XAMPP to access my custom folder
# OLD ENTRY: User daemon
User Ljonja
But I still get the error 403 on localhost (access forbidden). How do I solve this? I even reinstalled it and did many times of restarting the webserver, or clearing browser cache or trying other browsers ...
I set up the Apache server via brew ( https://tecadmin.net/install-apache-macos-homebrew/ ), big thanks to @AndreC23 for quickly mentioning this idea at the end of your post.
NB: if you are using MacOS i suggest you to install Apache and MariaDB as modules using brew. See: Install & configure apache brew
In the linked tutorial, both User
and Group
had to be changed in the httpd.conf
:
User ljonja
Group staff
Maybe this is also working out at XAMPP, but will be using the brew-variant.