After fresh installation of XAMMP (LAMPP) you get this 403 error when accessing phpMyAdmin using browser.
It is due to new security rule according to which access to the requested directory is only available from the local network. So here are the step-by-step solution:
Note: (All file location are under assumption that lampp installation directory exists under opt directory, if you have lampp installed elsewhere, change it according wise)
1. Open the httpd-xampp.conf file at the location /opt/lampp/etc/extra/httpd-xampp.conf using a text editor (nano here) after going root in the terminal:
2. Search for the text #New XAMPP security concept and beneath that find the line Deny from all.
3. Replace the word Deny with Allow so that it becomes Allow from all :
4. Now search the text <Directory “/opt/lampp/phpmyadmin> and between this opening tag line and its closing tag line </Directory>, add the line Require all granted and save(overwrite) the file.
5. Now restart the XAMPP (LAMPP) using this command:
6. Now point your browser to http://localhost/phpmyadmin and test whether you did it right or not. (Yes we did it right! )