I went to the line and tried a few things.
(1) preg_quote($http_domain, ‘/’)
– This would change “\d.gravatar.com” to “\\d\.gravatar\.com”. Which is right, but we need the \d to be parsed as regexp.
(2) preg_match(‘|’ . $http_domain . ‘|’, $url, $matches);
– I changed the delimiters to another character, but again, we could be using it inside the regexp.
(3) str_replace(‘/’, ‘\/’, $http_domain)
– I just decided to use this one. It is working fine, no more warnings. Try it out and make the fix if applicable and/or give me a recommendation please.
Thanks.
Hi,
I’m having the same problem.
The “preg_match(): Unknown modifier ‘c’ in /home/grievingtogether/public_html/wp-content/plugins/wordpress-https/lib/WordPressHTTPS/Module/DomainMapping.php on line 43”
isn’t on all the pages. Main homepage, main tabs are working fine. Except when I go to the menu and scroll down and select.
I’m not sure what’s going on.
The website is http://www.olivias4tea.com
You can see the error on https://olivias4tea.com/olivias-dollhouse-tea-room/
Any help would be greatly appreciated.
Thanks
Go to the file and line below:
/wp-content/plugins/wordpress-https/lib/WordPressHTTPS/Module/DomainMapping.php on line 43
Replace:
preg_match(‘/’ . $http_domain . ‘/’, $url, $matches);
With:
preg_match(‘/’ . str_replace(‘/’, ‘\/’, $http_domain) . ‘/’, $url, $matches);
Glad to help. You’re welcome 🙂
Marking it as solve.
Well, actually, the plugin author should apply this fix. Hope he/she does. Still a great plugin! Thanks.
Perhaps they should but I guess they didn’t ’cause I ran into the same problem (WordPress 4.0, plugin WordPress HTTPS 3.3.6) but with a ‘p’ instead of ‘c’. But it seems like the same solution as you proposed above did the trick, again 🙂
Great stuff, thanks !
No more Warnings 🙂
https://norton.alterlinks.com