2013-05-05, 12:12:16
I found an odd behaviour of find_i18n_url function in GS 3.2.1 with furls enabled.
Example code I use:
outputted link on non default language pages contains doubled lang in url, so it looks like:
Website works, as GS along with i18n rewrite rules do not cover nested pages below 2nd level.
Looking at a backup based on GS 3.2 same problem occur.
Tried with i18n 3.05 and latest 3.1.
Might it be a problem with custom rewrite rules ?
I've got also two more questions:
1. Is there also a way of getting rid of getting a link containing default language switch in this function ? Because links will be duplicated when using custom url structure with %nondefaultlanguage% ...
2. I wanted to get a standalone link to parent (in respective language), and show it on all its slugs.
Is there maybe a builtin' function for this, rather than using below sample code ?
Example code I use:
Code:
find_i18n_url('samplepage',$language);
Code:
http://website/en/en/samplepage
Looking at a backup based on GS 3.2 same problem occur.
Tried with i18n 3.05 and latest 3.1.
Might it be a problem with custom rewrite rules ?
I've got also two more questions:
1. Is there also a way of getting rid of getting a link containing default language switch in this function ? Because links will be duplicated when using custom url structure with %nondefaultlanguage% ...
2. I wanted to get a standalone link to parent (in respective language), and show it on all its slugs.
Is there maybe a builtin' function for this, rather than using below sample code ?
Code:
$bc = return_i18n_breadcrumbs(return_page_slug());
echo '<a href="'.find_i18n_url($bc[0]['url'],$language)">'.$bc[0]['menu'].'</a></li>';
Addons: blue business theme, Online Visitors, Notepad