-
-
Notifications
You must be signed in to change notification settings - Fork 4.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Call to undefined function mysql_connect() (PHP5.6.35, MYSQL5.7, APACHE2) #1483
Comments
Do you have the extension installed?
docker exec $container_name docker-php-ext-install mysql
docker restart $container_name |
Actually, the extension was not installed, but this should already be automatic at the time of mounting the container, I will study laradock, and try to develop this, for now I am still exploring the tool. Many thanks for the help; |
Any update how this could be persistently done? |
@hlorofos you can put the code (that was suggested by @philippeboyd) in your Dockerfile. Or even send PR. The problem is, it probably will not be merged, because the 5.6 EOL is in 2 mouths from now. |
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. |
Hi again 👋 we would like to inform you that this issue has been automatically |
Info:
Issue:
According to information the mysql_connect function was deprecated in version 7.0 of PHP, but when I set up the environment with PHP 5.6.35, my projects with this function do not work
Expected behavior:
The use of this method should occur naturally.
Reproduce:
`<?php
$link = mysql_connect('localhost', 'mysql_user', 'mysql_password');
if (!$link) {
die('Could not connect: ' . mysql_error());
}
echo 'Connected successfully';
mysql_close($link);
?>`
The text was updated successfully, but these errors were encountered: