Have you looked at the line in the file that was causing the issue for me and seen what the line is about. I should have the correct DBHost, name and password.
You do not have the correct "DBHost, name and password".
That specific line is the mysql_connect line. It's the line where it is trying to connect to your database. To do that, it needs to know the correct hostname, username, and password for that database.
Since the information you have in the configuration file is incorrect, it cannot connect, and so you get an error on that line because that is the line where the error occurs. The error is caused by the bad information, not by the code itself.
Correct the information in your wp-config.php file. Then the problem will go away.