Upgrading to PHP 7.2 (from 7.0) broke MySQLi functions on NGINX serverCatch output from “nginx -t” with phpNginx is downloading file instead of doing MySql queryHow to configure php.ini to send mail from external smtp using ssmtp?Can't get nginx to run php on ubuntu 16.04 serverwhich is correct php.ini file to use in apache2?Failed to implement Nginx caching - connection refusedLAMP mysqli and PDO is connected but mysql is not connectingCan't increase upload_max_filesizeShould all four PHP.ini be identicalHTTP/2 in Apache Web Server - cannot use php function sqlsrv_connect()
Quoting Keynes in a lecture
What to do when eye contact makes your subordinate uncomfortable?
Can disgust be a key component of horror?
Is there a RAID 0 Equivalent for RAM?
Electoral considerations aside, what are potential benefits, for the US, of policy changes proposed by the tweet recognizing Golan annexation?
How should I respond when I lied about my education and the company finds out through background check?
Using substitution ciphers to generate new alphabets in a novel
How can I write humor as character trait?
What features enable the Su-25 Frogfoot to operate with such a wide variety of fuels?
Why would a new[] expression ever invoke a destructor?
Pre-mixing cryogenic fuels and using only one fuel tank
Are Captain Marvel's powers affected by Thanos' actions in Infinity War
How to cover method return statement in Apex Class?
creating a ":KeepCursor" command
Why Shazam when there is already Superman?
Why did the EU agree to delay the Brexit deadline?
User Story breakdown - Technical Task + User Feature
How do I delete all blank lines in a buffer?
Why can Carol Danvers change her suit colours in the first place?
What is Cash Advance APR?
Limits and Infinite Integration by Parts
putting logo on same line but after title, latex
Why does the Sun have different day lengths, but not the gas giants?
Do the primes contain an infinite almost arithmetic progression?
Upgrading to PHP 7.2 (from 7.0) broke MySQLi functions on NGINX server
Catch output from “nginx -t” with phpNginx is downloading file instead of doing MySql queryHow to configure php.ini to send mail from external smtp using ssmtp?Can't get nginx to run php on ubuntu 16.04 serverwhich is correct php.ini file to use in apache2?Failed to implement Nginx caching - connection refusedLAMP mysqli and PDO is connected but mysql is not connectingCan't increase upload_max_filesizeShould all four PHP.ini be identicalHTTP/2 in Apache Web Server - cannot use php function sqlsrv_connect()
I'm hosting a web server (using NGINX) with a MySQL database backend. It was working previously with PHP 7.0, but when I installed some updates, apparently the system upgraded me to PHP 7.2. I'm using NGINX and php/7.2/fpm on Ubuntu 18.x
My login page is failing on a function call to mysqli_connect() even though I'm sure the database access information is correct. The exact error message in /var/log/nginx is:
PHP Fatal error: Uncaught Error: Call to undefined function mysqli_connect() in [filename]
I've tried editing the /etc/php/7.2/fpm/php.ini file and uncommented the extention=mysqli line. I've also tried adding every other extension that I've come across (mysqli.so, mysqli.dll, etc.) to no avail.
I've uninstalled PHP 7.0 (the previous version I was using) completely. When I load info.php in my browser to view PHP information, it says "PHP version 7.2.15-0ubuntu0.18.04.1" but there is no reference to "mysqli" anywhere in the file. The loaded configuration file is indeed the one I edited (/etc/php/7.2/fpm/php.ini)
Has anyone run into a similar issue, especially when upgrading from PHP 7.0 to PHP 7.2? I know mysqli was deprecated after PHP 5, but that's not the issue here, since this was completely working with PHP 7.0 and I'm using all mysqli (not mysql) functions.
Thanks for the help
server mysql php nginx
New contributor
scattanach1 is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
add a comment |
I'm hosting a web server (using NGINX) with a MySQL database backend. It was working previously with PHP 7.0, but when I installed some updates, apparently the system upgraded me to PHP 7.2. I'm using NGINX and php/7.2/fpm on Ubuntu 18.x
My login page is failing on a function call to mysqli_connect() even though I'm sure the database access information is correct. The exact error message in /var/log/nginx is:
PHP Fatal error: Uncaught Error: Call to undefined function mysqli_connect() in [filename]
I've tried editing the /etc/php/7.2/fpm/php.ini file and uncommented the extention=mysqli line. I've also tried adding every other extension that I've come across (mysqli.so, mysqli.dll, etc.) to no avail.
I've uninstalled PHP 7.0 (the previous version I was using) completely. When I load info.php in my browser to view PHP information, it says "PHP version 7.2.15-0ubuntu0.18.04.1" but there is no reference to "mysqli" anywhere in the file. The loaded configuration file is indeed the one I edited (/etc/php/7.2/fpm/php.ini)
Has anyone run into a similar issue, especially when upgrading from PHP 7.0 to PHP 7.2? I know mysqli was deprecated after PHP 5, but that's not the issue here, since this was completely working with PHP 7.0 and I'm using all mysqli (not mysql) functions.
Thanks for the help
server mysql php nginx
New contributor
scattanach1 is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
Trysudo apt install php7.2-mysqland then edit your question with the output.
– Parto
3 mins ago
add a comment |
I'm hosting a web server (using NGINX) with a MySQL database backend. It was working previously with PHP 7.0, but when I installed some updates, apparently the system upgraded me to PHP 7.2. I'm using NGINX and php/7.2/fpm on Ubuntu 18.x
My login page is failing on a function call to mysqli_connect() even though I'm sure the database access information is correct. The exact error message in /var/log/nginx is:
PHP Fatal error: Uncaught Error: Call to undefined function mysqli_connect() in [filename]
I've tried editing the /etc/php/7.2/fpm/php.ini file and uncommented the extention=mysqli line. I've also tried adding every other extension that I've come across (mysqli.so, mysqli.dll, etc.) to no avail.
I've uninstalled PHP 7.0 (the previous version I was using) completely. When I load info.php in my browser to view PHP information, it says "PHP version 7.2.15-0ubuntu0.18.04.1" but there is no reference to "mysqli" anywhere in the file. The loaded configuration file is indeed the one I edited (/etc/php/7.2/fpm/php.ini)
Has anyone run into a similar issue, especially when upgrading from PHP 7.0 to PHP 7.2? I know mysqli was deprecated after PHP 5, but that's not the issue here, since this was completely working with PHP 7.0 and I'm using all mysqli (not mysql) functions.
Thanks for the help
server mysql php nginx
New contributor
scattanach1 is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
I'm hosting a web server (using NGINX) with a MySQL database backend. It was working previously with PHP 7.0, but when I installed some updates, apparently the system upgraded me to PHP 7.2. I'm using NGINX and php/7.2/fpm on Ubuntu 18.x
My login page is failing on a function call to mysqli_connect() even though I'm sure the database access information is correct. The exact error message in /var/log/nginx is:
PHP Fatal error: Uncaught Error: Call to undefined function mysqli_connect() in [filename]
I've tried editing the /etc/php/7.2/fpm/php.ini file and uncommented the extention=mysqli line. I've also tried adding every other extension that I've come across (mysqli.so, mysqli.dll, etc.) to no avail.
I've uninstalled PHP 7.0 (the previous version I was using) completely. When I load info.php in my browser to view PHP information, it says "PHP version 7.2.15-0ubuntu0.18.04.1" but there is no reference to "mysqli" anywhere in the file. The loaded configuration file is indeed the one I edited (/etc/php/7.2/fpm/php.ini)
Has anyone run into a similar issue, especially when upgrading from PHP 7.0 to PHP 7.2? I know mysqli was deprecated after PHP 5, but that's not the issue here, since this was completely working with PHP 7.0 and I'm using all mysqli (not mysql) functions.
Thanks for the help
server mysql php nginx
server mysql php nginx
New contributor
scattanach1 is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
New contributor
scattanach1 is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
New contributor
scattanach1 is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
asked 1 hour ago
scattanach1scattanach1
1
1
New contributor
scattanach1 is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
New contributor
scattanach1 is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
scattanach1 is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
Trysudo apt install php7.2-mysqland then edit your question with the output.
– Parto
3 mins ago
add a comment |
Trysudo apt install php7.2-mysqland then edit your question with the output.
– Parto
3 mins ago
Try
sudo apt install php7.2-mysql and then edit your question with the output.– Parto
3 mins ago
Try
sudo apt install php7.2-mysql and then edit your question with the output.– Parto
3 mins ago
add a comment |
0
active
oldest
votes
Your Answer
StackExchange.ready(function()
var channelOptions =
tags: "".split(" "),
id: "89"
;
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function()
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled)
StackExchange.using("snippets", function()
createEditor();
);
else
createEditor();
);
function createEditor()
StackExchange.prepareEditor(
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader:
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
,
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
);
);
scattanach1 is a new contributor. Be nice, and check out our Code of Conduct.
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2faskubuntu.com%2fquestions%2f1127939%2fupgrading-to-php-7-2-from-7-0-broke-mysqli-functions-on-nginx-server%23new-answer', 'question_page');
);
Post as a guest
Required, but never shown
0
active
oldest
votes
0
active
oldest
votes
active
oldest
votes
active
oldest
votes
scattanach1 is a new contributor. Be nice, and check out our Code of Conduct.
scattanach1 is a new contributor. Be nice, and check out our Code of Conduct.
scattanach1 is a new contributor. Be nice, and check out our Code of Conduct.
scattanach1 is a new contributor. Be nice, and check out our Code of Conduct.
Thanks for contributing an answer to Ask Ubuntu!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2faskubuntu.com%2fquestions%2f1127939%2fupgrading-to-php-7-2-from-7-0-broke-mysqli-functions-on-nginx-server%23new-answer', 'question_page');
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Try
sudo apt install php7.2-mysqland then edit your question with the output.– Parto
3 mins ago