Do one thing just rename the wp-config-sample.php file make it(wp-config.php)
and add the below details.
define( 'DB_NAME', 'database name here' );
/** Database username */
define( 'DB_USER', 'database user name' );
/** Database password */
define( 'DB_PASSWORD', 'database password' );
/** Database hostname */
define( 'DB_HOST', 'localhost' );
Then make the (define( ‘WP_DEBUG’, true );)
You will see the error on the frontend.
I hope this will help you.