Skip to content Skip to sidebar

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.

Sun Mon Tue Wed Thu Fri Sat
- 11:00 – 15:00 11:00 – 15:00 11:00 – 15:00 11:00 – 15:00 11:00 – 15:00 -
- 16:00 – 20:00 16:00 – 20:00 16:00 – 20:00 16:00 – 20:00 16:00 – 20:00 -

Supporter timezone: Europe/Rome (GMT+02:00)

This topic contains 1 reply, has 2 voices.

Last updated by Laura 1 year, 2 months ago.

Assisted by: Laura.

Author Posts
May 16, 2024 at 11:51 am #15634832

nickG-26

I Wanted to use a translation plugin to translate my website.
Previously I was already using the WooCommerce Multilingual & Multicurrency plugin and was happy about it.

I dicided to buy a plan with you to use the translation functionality as well.
After that i installed the installer plugin, and used that to install:
- WPML Multilingual CMS
- WPML String Translation

Whenever I install the second one, WPML String Translation, my site gets an Fatal error, and I have to deactivateone of the two latter plugins to get my site working again.

I checked the requirements defined at https://wpml.org/home/minimum-requirements/
All requirements are met.

After this I checked for theme compatibility using your online tool, and the theme i'm using, and other themes installed are also supported.

Then I checked for plugin compatibility with the online tool, and found some plugins that i'm using were'nt defined in the tool.
I tried deactivating those plugins, but still no result.

My conclusion was that it does not have anything to do with theme/plugin compatibility.

Then i looked at the php error logs to see whats going on there and found out that whenever I have the combination of WPML Multilingual CMS and WPML String Translation plugins active I get errors stating that it cannot redeclare certain functions:
[08-May-2024 08:34:07 UTC] PHP Fatal error: Cannot redeclare icl_st_init() (previously declared in /home/kukudu5/public_html/kukudushi.com/wp-content/plugins/wpml-string-translation/inc/functions.php:17) in /home/kukudu5/public_html/kukudushi.com/wp-content/plugins/wpml-string-translation/inc/functions.php on line 17

I edited the code in the file by using the php function_exists for the function in question and then i got this error:
[08-May-2024 08:41:58 UTC] PHP Fatal error: Cannot redeclare wpml_st_init_register_widget_titles() (previously declared in /home/kukudu5/public_html/kukudushi.com/wp-content/plugins/wpml-string-translation/inc/functions.php:124) in /home/kukudu5/public_html/kukudushi.com/wp-content/plugins/wpml-string-translation/inc/functions.php on line 124

The weird thing is that is is complaining that the function is already declared, but when you look at the full error message, it says it is already declared in exactly the same php file.

Now I'm thinking that for some reason it is including the same plugin twice or something like that.
I deleded and reinstalled both plugins a couble of times already but with no results..
The weird thing is that when i ONLY have the WPML String Translation plugin active, I don't get any errors.
The same thing goes for WPML Multilingual CMS.
It's the combination of those two that result in a Fatal Error.

What can I do to resolve this issue?

I'm using a custom child theme based on the theme: Hello Elementor.

Heres a full list of my installed plugins for reference:

[removed]

May 16, 2024 at 11:53 am #15634833

Laura
WPML Supporter since 05/2018

Languages: English (English ) Italian (Italiano )

Timezone: Europe/Rome (GMT+02:00)

I split the ticket because from the 2nd tier asked more information about how to reproduce the issue. Specifically which page they should look at.

The topic ‘[Closed] Cannot redeclare icl_st_init()’ is closed to new replies.