[Resolved] Problem activing WPML String Translation
This thread is resolved. Here is a description of the problem and solution.
Problem:
WPML String Translation wasn't being activated and when trying to activate, site's main menu and header were gone. There was a fatal error when trying to access Avada Options page and site was breaking.
For some reason, the main site was expecting to use FTP. This is why nothing actually worked. And nothing was being logged in debug.log.
By using Query Monitor, our team was able to find following error:
Fatal error: Uncaught Error: ftp_nlist(): Argument #1 ($ftp) must be of type FTP\Connection, null given
in /wp-admin/includes/class-wp-filesystem-ftpext.php on line 427
Call stack:
ftp_nlist()
wp-admin/includes/class-wp-filesystem-ftpext.php:427
WP_Filesystem_FTPext::exists()
wp-content/themes/Avada/includes/class-avada-server-rules.php:177
Avada_Server_Rules::is_htaccess_writable()
wp-content/themes/Avada/includes/options/performance.php:53
avada_options_section_performance()
wp-content/themes/Avada/includes/class-avada-options.php:155
Avada_Options::set_sections()
wp-content/themes/Avada/includes/class-avada-options.php:107
Avada_Options::__construct()
wp-content/themes/Avada/includes/class-avada-options.php:124
Avada_Options::get_instance()
wp-content/themes/Avada/includes/class-avada.php:716
Avada::get_options()
wp-content/themes/Avada/includes/class-avada-avadaredux.php:30
Avada_AvadaRedux::init_fusionredux()
wp-includes/class-wp-hook.php:308
WP_Hook::apply_filters()
wp-includes/class-wp-hook.php:332
WP_Hook::do_action()
wp-includes/plugin.php:517
do_action()
wp-settings.php:623
require_once()
wp-config.php:104
require_once()
wp-load.php:50
require_once()
wp-admin/admin.php:34
require_once()
wp-admin/themes.php:10
Solution:
Team fixed the issue by adding:
define('FS_METHOD', 'direct');
to wp-config.php file.
This seems to work with:
- String Translation - no crashes
- Visiting Avada Options - no crashes
- Front-end - the menu displays just properly now when WPML String Translation is enabled.
This is also actually the reason why no error log was created in the first place.
This is the technical support forum for WPML - the multilingual WordPress plugin.
Everyone can read, but only WPML clients can post here. WPML team is replying on the forum 6 days per week, 22 hours per day.
Its me again, just adding to my previous message that after bringing your site up, can you please take the latest debug.log file from /wp-content/ folder and share again?
Since I can't reproduce the issue on my local, I need to look into yours.
Thank you for providing the debug log but I don't see any error after April 14th (last error was recorded on 14-Apr-2023 07:01:12 UTC).
Can you enable debugging again, browse a few pages then try activating ST, so it logs fresh errors and send me again?
Since when I tried to do this a few times previously in your website (specially activating ST), site becomes unreachable. That's why I am kindly asking you for this.
Thank you for providing the updated log, you are right there are no new errors.
But one thing is very confusing. I logged into your staging site at hidden link and saw that WPML String Translation is active. I also connected via FTP to check if staging site has that debug.log but found no log there.
However, as soon as tried to visit the home page of staging site, I see that both production and staging sites are not reachable anymore, getting "ERR_CONNECTION_TIMED_OUT".
See attached images.
The confusion is about site's stability, why this goes down without doing anything. This time I didn't even try to activate ST. Can you check with service provider about this? Because I am trying to escalate the original problem about ST, the Menu, the header and the WordPress interface disappearance but site is being unstable. So I am not sure if team 'll be able to work smoothly.
Although I have your duplicator package and on PHP 7.4 that works just fine without any problem. It may be about PHP version 8 but can't be sure at this moment. Team may need to investigate and then compare with your site.
So, in the meanwhile, please check for site's stability and let me know.
Yes, I already told you, first I tried the staging site and everything worked perfectly for me and I was able to install and activate the WPML plugins. I don't understand why not on the production site.
Now, both production and staging sites, they work without problem for me. I don't undestand your problem.
Tell me exactly what you want me to ask my service provider about the stability of the site and I'll ask it tomorrow. It's already night here.
Thank you for the updates. So these are working fine for you, then probably something wrong from my location (i.e. access restrictions or instable network).
Never mind and my apologies, you can leave it for now.
I've already escalated the issue, and I hope our team 'll not face this problem, since they are in different locations.
However, I'll update you as soon as I've more information about actual/reported issue.
Yes sure you can continue with your production site as you want to work. I am trying to reproduce the issue on one of our servers by replicating the same environment as yours.
I've your site package and working based on that. I'll update you as soon as I progress further.
I tried your site package on one of our test sites and was able to activate WPML String Translation without any problem. This server also uses PHP 8.1. I found a couple of plugins throwing notices but those are not relevant to WPML.
So after some discussion with our 2nd tier team, I'll further escalate the issue.
But since this is only happening in your Production Site, which is using different versions of PHP 8 and MySQL. Team suggest that if you can try the following versions:
- PHP 8.1.12
- MySQL 10.4.20-MariaDB-1
and see if issue is resolved? You can also try different version than the mentioned and different than what's currently on the server. It is better to try with PHP's first.
IMPORTANT: Take full backup of your website and database beforehand.
Please let me know your findings. If a particular version works for you and you want to continue with that (i.e. no hard requirements), then it's good.
But if you want to stick with current PHP/MySQL versions (PHP: 8.0.28, MySQL: 8.0.30), please restore back those versions and then I'll need your permissions to debug and analyze the issue (by our 2nd tier team). Please NOTICE that we may break things as we 'll be debugging on the LIVE SITE.
I've set your next reply as private again, in case if you want to provide updated credentials to the site (Site + FTP), only if you approve (please mention clearly).
I've escalated the matter further, along with your site access details. Our team 'll look into the matter and the site directly and hopefully we 'll be able to sort this out soon.
I (or one of our 2nd tier team member) 'll keep you posted.
Hello!
I am George from 2nd tier support and I am in charge in debugging the issue that you have.
Currently, I am accessing your site and I have activated WPML String Translation.
There is no error, but the header is indeed "missing".
I am putting that in quotes because it seems that it is hidden for some reason.
The work on your site seems quite slow - mainly because after I visit the site 1 or two times and try to test something - I get locked out and blocked.
I confirmed that I am blocked because I ran test on gtmetrix on your site and your site is accessible - but not for my IP address.
Perhaps you can temporarily disable any security measures that you might have so that we have a smooth testing experience and be able to help you faster.
Another thing that I see (the site partially loaded) is that the header is there, but it is somewhat hidden - this could be either due to the "fusion_options_" key having different value in "fusion_options_es" or because of custom CSS applied or even because of the header template having specific language settings - I can only guess at this point because I am locked out currently (usually locked out for 10-15minutes at least).
I do not have any security measures enabled on my server that prevent your connection. I have asked the technical support department of my server about it and they have recommended me to increase the values to the maximum in the PHP configuration (attached screen).
I have deactivated and activated the WPML String Translation plugin several times and the problem remains the same.
I've relayed your message to the team and 'll get back to you with further progress.
Regards.
Manage Cookie Consent
We use cookies to optimize our website and services. Your consent allows us to process data such as browsing behavior. Not consenting may affect some features.
Functional
Always active
Required for our website to operate and communicate correctly.
Preferences
The technical storage or access is necessary for the legitimate purpose of storing preferences that are not requested by the subscriber or user.
Statistics
We use these to analyze the statistics of our site. Collected information is completely anonymous.The technical storage or access that is used exclusively for anonymous statistical purposes. Without a subpoena, voluntary compliance on the part of your Internet Service Provider, or additional records from a third party, information stored or retrieved for this purpose alone cannot usually be used to identify you.
Marketing
These cookies track your browsing to provide ads relevant to you.