- "SELECT q.profile_mobile AS cell, a.naissance AS age
- FROM auth_user_md5 AS a
- INNER JOIN auth_user_quick AS q USING (user_id)
- WHERE a.matricule = {?}", $params[1]);
+ "SELECT ph.display_tel AS cell, a.naissance AS age
+ FROM auth_user_md5 AS a
+ INNER JOIN auth_user_quick AS q USING (user_id)
+ LEFT JOIN profile_phones AS ph ON (ph.uid = a.user_id AND link_type='user' AND tel_type = 'mobile')
+ WHERE a.matricule = {?} LIMIT 1", $params[1]);