Reading default language of email recipient

Get help from other users here.

Moderators: Developer, Contributor

Post Reply
pwc
Posts: 8
Joined: Oct 25, 2011 6:32 am

Reading default language of email recipient

Post by pwc » Mar 12, 2012 4:19 am

hi,

i'd like to get the default language of the user who is recieving an email, e.g while adding a comment to an issue. I can't find the right function in the php code to read it out... does anyone know this function?

istvanb
Posts: 226
Joined: Aug 22, 2010 4:00 pm

Re: Reading default language of email recipient

Post by istvanb » Mar 12, 2012 4:33 am

I think this could help. This is coming from the account_pref_update.php

$f_user_id = gpc_get_int( 'user_id' );
$t_prefs = user_pref_get( $f_user_id );


then

echo($t_prefs->language);

will give you the language of the current user.

Post Reply