Closed gormus closed 4 years ago
Hi @gormus,
I'm as puzzled as you but I believe this is a WordPress issue, nothing to do with WPP.
In my experience, this error message often refers to database port if it's defined as a string, in the db connection strings. However, this is puzzling, since WordPress doesn't even have a constant for the db port, or it's defined anywhere.
According to the documentation, you can specify the port number via the DB_HOST
constant:
If your host uses an alternate port number for your database you’ll need to change the DB_HOST value in the
wp-config.php
file to reflect the alternate port provided by your host.
Eg. define( 'DB_HOST', 'localhost:3307' );
WordPress then will attempt to extract the port number from that string (if present) and pass it to the mysqli_real_connect()
function (see related code here) without explicitly converting it into an integer first which might be the reason why mysqli_real_connect()
is complaining.
Assuming you didn't configure a port number in your DB_HOST
constant, try setting it up and see if it helps. Other than that I'm honestly out of ideas.
Thank you for your prompt response @cabrerahector!
I was hesitant, and I was going to try what you suggested in your reply as a backup plan; I guess I was hoping you might have an alternative solution.
Much appreciated though. I'll keep posted with my findings.
Hi @cabrerahector and anyone who experiences the same issue,
Setting the database host and the port together completely resolved the issue for me. No more errors.
define( 'DB_HOST', 'localhost:3306' );
Due to support has been dropped for qTranslate-XT, we have to use WPP < 5.0 for the time being.
Thought I should let you know, Osman: https://wordpress.org/support/topic/translation-fails-since-last-update/#post-12274242
@cabrerahector I only recently had a chance to upgrade the WPP to latest. Works flawlessly with qTranslate-XT. Thanks Hector!
Describe the bug My log is filled with so many messages like this, and all seems to be pointing to WPP plugin:
Expected behavior No errors to log for.
Environment:
Additional context Due to support has been dropped for qTranslate-XT, we have to use WPP < 5.0 for the time being.
In my experience, this error message often refers to database port if it's defined as a string, in the db connection strings. However, this is puzzling, since WordPress doesn't even have a constant for the db port, or it's defined anywhere.