[Plugin: Polylang] Rewrite rules not correct
-
Hi,
when using
– Hide URL language information for default language
– Add language information to all URL
-setting the default language to be first in orderthe rewriterules become:
[(.?.+?)(/[0-9]+)?/?$] => index.php?pagename=$matches[1]&page=$matches[2]
[tr/(.?.+?)(/[0-9]+)?/?$] => index.php?pagename=$matches[1]&page=$matches[2]the first line matching the other ones as well.
thus with a url like
tr/blabla
the pagename matches is ‘tr/blabla’ on the first rule and not
‘blabla’ on the secondchanging the order of the language and flushing the rules gives
[tr/(.?.+?)(/[0-9]+)?/?$] => index.php?pagename=$matches[1]&page=$matches[2]
[(.?.+?)(/[0-9]+)?/?$] => index.php?pagename=$matches[1]&page=$matches[2]and a correct working site
The topic ‘[Plugin: Polylang] Rewrite rules not correct’ is closed to new replies.