I am using MAMP on windows 10, and I'm trying to install WordPress but it gives me "Error establishing a database connection
".
It's connected to MySQL okay, as it shows the box checked in the MAMP UI.
I've tried following:
127.0.0.1
instead of localhost
.wp-config.php
.define('WP_ALLOW_REPAIR', true);
.Why I am getting this error and how can I resolve it?
After many investigations. turned out I was accessing localhost as a host, but while I reset the MAMP ports to default, it uses 8889 and not 8888 or localhost.