Quantcast
Channel: Issues for Drupal core
Viewing all articles
Browse latest Browse all 299319

Provide a token for the site's base URL

$
0
0

Hi,

my multilanguage site is configured to show language prefixes on paths, but didn't expect to see the language prefix in the value of the[site-url] token too, and it seems it is not possible to pass options for the global tokens either in token_token_values().

To prevent the language prefix from showing in the url, we can use this snippet

$values['site-url']     = url('<front>', array('absolute' => TRUE, 'language' => ''));

Let me know if the change looks OK to you, in this case I can send a proper patch.

Thanks,
Antonio


Viewing all articles
Browse latest Browse all 299319

Latest Images

Trending Articles



Latest Images

<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>