How to add Profile action link for different criterias?

Feb 2, 2008 at 10:28 AM
Hello Friends I would like to know that How to add profile action links on profile page. I have to satisfy 3 conditions for displaying profile action link.
1. User viewing profile is application user. Profile being viewed is of application user.

2. User viewing profile is not application user. Profile being viewed is of application user.

3. User viewing profile is application user. Profile being viewed is of non-application user.

I have used this code but it does not works

$displayFBML .='<fb:if-is-app-user uid="'.$user.'">
<fb:profile-action url="http://apps.facebook.com/superrps/">First Statement here</fb:profile-action>
<fb:else>
<fb:profile-action url="http://apps.facebook.com/superrps/"> Second Statement here</fb:profile-action>
</fb:else>
</fb:if-is-app-user>';
$facebook->apiclient->profilesetFBML($displayFBML,$user);

Please suggest something.