I am using Internationalization module to translate content. How to get work this module with l function?
for example, when I create programatically link to content:
l(t('About us'), 'node/22');
I would like to achieve, that path 'node/22' will change when I switch website to another language. With Internationalization module, each translation of node creates another node, so I need to change paths in links on website.
For this time, I can create just if-else condition:
<?php if ($language->language == 'en') $output = l(t('About us'), 'node/22'); elseif (($language->language == 'de') $output = l(t('About us'), 'node/23'); ?>
IS it possible to use l function in that way, that I don't need to write else-if condition?