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
- 8:00 – 13:00 9:00 – 13:00 9:00 – 13:00 8:00 – 12:00 8:00 – 12:00 -
- 14:00 – 17:00 14:00 – 18:00 14:00 – 18:00 13:00 – 17:00 13:00 – 17:00 -

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

This topic contains 1 reply, has 2 voices.

Last updated by Bruno Kos 1 year, 4 months ago.

Assisted by: Bruno Kos.

Author Posts
March 1, 2024 at 9:04 am #15361520

matteoS-4

I have the same problem as this guy here https://wpml.org/forums/topic/error-php-warning-preg_match-unknown-modifier/ and find it fascinating how non-helpful the answers were.

In my installation I added a workaround that solves the problem, the following lines on line 181 in /wp-content/plugins/sitepress-multilingual-cms/inc/absolute-links/absolute-links.class.php

if(str_contains($match, '-'))
continue;

It works for me now, but I would encourage you guys to re-open the other thread.

Screenshot 2024-03-01 at 10.01.54.png
March 1, 2024 at 9:38 am #15361822

Bruno Kos
WPML Supporter since 12/2018

Languages: English (English ) German (Deutsch ) French (Français )

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

Hi,

Thank you for contacting WPML support!

If I prepare a sandbox website for you, is there any way you can show us there? Or do you think this is related only to your setup?

Because even though it works in your case, I would still like to check with our 2nd tier because we have a complex set of plugins and even the slightest change such as the one you proposed above may interfere with something else, I saw want to make sure we are on the safe side here.

Regards,
Bruno Kos

The topic ‘[Closed] Error PHP Warning: preg_match(): Unknown modifier '-'’ is closed to new replies.