如何在Facebook页面上获取用户的uid?

I have a question !

I wanna do customize message on my tabs on my Facebook page. Ex : Hello Steffi or Hello Kevin

How can I do that please ?

fb:user ?

thanks !

Hello, <fb:name uid="1234567890" captialize="true" firstnameonly="true" useyou="false"><a class="fb_link" href="http://www.facebook.com/profile.php?id=534481565">Kim's</a></fb:name>

You'd replace "1234567890" with the user ID of the user you want to display the name of.

The PHP SDK has an example getting the logged in user's ID:

https://github.com/facebook/php-sdk/blob/master/examples/example.php

I am using this code snippet and it works like a charm.

<div id="fb-root"></div>
<script>
    window.fbAsyncInit = function() {
        FB.init({
            appId: 'APP_ID',
            cookie: true,
            xfbml: true,
            oauth: true
        });


    };
    (function() {
        var e = document.createElement('script'); e.async = true;
        e.src = document.location.protocol +
            '//connect.facebook.net/en_US/all.js';
        document.getElementById('fb-root').appendChild(e);
    }());
</script>
<fb:serverFbml>
    <script type="text/fbml">
        <div style="font-size:2em;" >
            Hello, <fb:userlink uid="loggedinuser"/>
        </div>
    </script>

</fb:serverFbml>

and yes do not for get to put <html xmlns:fb="http://www.facebook.com/2008/fbml"> at the top of it.

Thanks

Sachin