URL translation, WooCommerce, and other third part paths
-
Hi,
I noticed that several paths added by third-party plugins are not translated. The most obvious example may be in WooCommerce, such as:
-
Original:
https://domain.tld/en/my-account/edit-account/
Translated:
https://domain.tld/en/my-account/
This comes from
Falang_Public::get_translated_url( $language )
: indeed, the method requires a queried object or a WordPress system path (archive, search, etc) to translate URLs, but is unaware of other kinds of URL rewrites.Would it be possible to:
-
Amend
falang/src/Falang/Filter/Site/WooCommerce.php
to take all WooCommerce paths into account?At the very least (as this is low hanging fruit), provide a filter for developers in
Falang_Public::get_translated_url( $language )
, returningapply_filters( 'falang_get_translated_link', $link, $language )
instead of the raw$link
?
- The topic ‘URL translation, WooCommerce, and other third part paths’ is closed to new replies.