[development] URL function with i18n localization

Mukesh Agarwal mukesh.agarwal17 at gmail.com
Tue Mar 13 11:51:52 UTC 2012


Hi Guys,

I'm using rate module for voting. When an anonymous user clicks on the
voting widget, the user is redirected to a url "user/login-to-rate". I'm
also using i18n for localization. The issue with both of these together is
that when I'm on a page with the URL "en/my-url" and I click on the voting
widget, I'm redirected to "de/user/login-to-rate" where "de" is my default
language. Ideally the user should be going to "en/user/login-to-rate" i.e.
user selected language should be respected.

Going into details, I find that the rate module calls url function:

print url('user/login-to-rate', array('query' => $query, 'absolute' => TRUE
));
and here there is no language paramater that is passed which means the
default site language gets selected.

Am I missing something here in the configuration? Has anyone faced a
similar problem and can help?

-- 
Cheers,
Mukesh Agarwal
________________________________
Innoraft Solutions <http://www.innoraft.com>  || +91 8017220799
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.drupal.org/pipermail/development/attachments/20120313/b04373a1/attachment.html 


More information about the development mailing list