I'm trying to set my php for a bilingual Drupal website.

Here is my code:

<?php
global $user;
if ( $user->uid ) {
print '<a href="'.base_path().'user/logout">Log out</a>';
print '<a href="'.base_path().'user/">My Account</a>';
}
else {
print '<a href="'.base_path().'user/login">Log in</a>';
print '<a href="'.base_path().'user/register">Create Account</a>';
}
?>

How can I set it up such as if language = en, then…., if language = fr, then…. ?

Your help would be really appreciated. I tried many things without success.

Dany !!!