Error establishing a database connection at localhost
Posted by: chadbiggs (---.dhcp.bhn.net)
Date: January 04, 2023 08:51PM

Wampserver 3 v3.0.4
Apache 2.4.18
PHP 7.0.4
MySQL 5.7.11
Green Wampserver icon in tray

Error: Error establishing a database connection
I receive this error on all wordpress folders in www folder.

I have been sick and have not opened Wamp for over a year. Since then, I upgraded to Windows 10.

Upon trying to open Wamp, I could not get Apache to work. I changed World Wide Web Publishing Service to manual in services.msc and was able to get Apache working. I now have a green icon in the tray.

When I click on localhost from the wamp icon it takes me to Windows IIS page and the address bar states that I am at localhost.

I am able to log into phpMyAdmin and see all my databases. I can see all my folders when I click on wwwdirectory.

I simply cannot connect any of my website databases from localhost.

I use Windows defender antivirus and I use windows firewall.
Wamp is installed at C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Wampserver32

Options: ReplyQuote
Re: Error establishing a database connection at localhost
Posted by: Otomatic (Moderator)
Date: January 05, 2023 08:51AM

Hi,

The switch to Windows 10 did not automatically perform the installation of redistributable VC++, so :

- Verify that all VC ++ packages are installed and with the latest versions.
To do this, use the tool:
Checks VC++ packages installed
Do not use a previously loaded tool. Make a new download to make sure you are using the correct version.
To download missing packages, do not rely on Microsoft links, they are not reliable, download packages on http://wampserver.aviatechno.net in section Visual C++ Redistribuable Packages
Do not forget that if you have a 64 bit Windows, you must install both 32 and 64 bit versions of each package.
You must install each package "as an administrator", so right-click the exe file and then run as Administrator.

Before applying the 3.3.0 update, it is necessary to perform some manipulations:
- Apply items 04 and 08 of TROUBLESHOOTING TIPS
- Install PHP 7.4.33
- Do PHP 7.4.33 for Wampserver scripts:
-- Edit wampmanager.conf to have:
phpCliVersion = "7.4.33"
then save it

- Apply Update 3.3.0 to your version of Wampserver
Wampserver update 3.3.0

> Wamp is installed at C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Wampserver32
No. It the shortcut

------------------------------------------------------------------------------------------------------------
Wampserver 3.3.0 32 bit - Apache 2.4.54.2 - PHP 8.2.0…7.4.33 - MySQL 5.7.40 - MariaDB 10.5.13/10.6.5
Wampserver 3.3.0 64 bit - Apache 2.4.54.2 - PHP 8.2.0…7.4.33 - MySQL 5.7.40/8.0.31 - MariaDB 10.5.17/10.10.2
PhPMyadmin 5.2.0 - MysqlDumper 1.24.5
on W10 Pro 64 bit
Documentation Apache - Documentation PHP - Documentation MySQL - Wampserver install files & addons
« Ce n'est pas parce qu'ils sont nombreux à avoir tort, qu'ils ont forcément raison. Coluche »
« It's not because they are many to be wrong, they are necessarily right. Coluche »

Options: ReplyQuote


Sorry, only registered users may post in this forum.