Warning: file_get_contents(/data/phpspider/zhask/data//catemap/4/jquery-ui/2.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Php Gravatar实现配置文件请求_Php_Profile_Gravatar - Fatal编程技术网

Php Gravatar实现配置文件请求

Php Gravatar实现配置文件请求,php,profile,gravatar,Php,Profile,Gravatar,我正试图从Gravatar检索信息到我的Joomla。我成功地从gravatar检索到了我的图像,但我正在努力检索其他配置文件信息。 $str = file_get_contents('http://www.gravatar.com/205e460b479e2e5b48aec07710c08d50.php' ); $profile = unserialize( $str ); if ( is_array( $profile ) && isset( $profile['

我正试图从Gravatar检索信息到我的Joomla。我成功地从gravatar检索到了我的图像,但我正在努力检索其他配置文件信息。
  $str = file_get_contents('http://www.gravatar.com/205e460b479e2e5b48aec07710c08d50.php' );
  $profile = unserialize( $str );
  if ( is_array( $profile ) && isset( $profile['entry'] ) )
    echo $profile['entry'][0]['displayName'];

    ?> 
下面的代码在gravatar文档中,它只输出我的gravatar名称。如何获得其他必要的个人资料信息?!我对PHP也有点陌生


多谢各位

对不起,我完全误解了你的问题:-D

如果用户自己设置了IMs、email和phone等值,则可以使用这些值。请记住,
$profile['entry'][0]['ims']
是一个数组,其中的键表示从零到数组长度减1

echo $profile['entry'][0]['emails'][0]['value'];
echo $profile['entry'][0]['ims'][0]['value']  ;
echo $profile['entry'][0]['ims'][0]['type']  ;
ims
array是这样的:

  ["ims"]=>
  array(6) {
    [0]=>
    array(2) {
      ["type"]=>
      string(3) "aim"
      ["value"]=>
      string(10) "checkmeout"
    }
    [1]=>
    array(2) {
      ["type"]=>
      string(3) "msn"
      ["value"]=>
      string(10) "checkmeout"
    }
    [2]=>
    array(2) {
      ["type"]=>
      string(5) "yahoo"
      ["value"]=>
      string(10) "checkmeout"
    }
    [3]=>
    array(2) {
      ["type"]=>
      string(3) "icq"
      ["value"]=>
      string(10) "checkmeout"
    }
    [4]=>
    array(2) {
      ["type"]=>
      string(5) "gtalk"
      ["value"]=>
      string(10) "checkmeout"
    }
    [5]=>
    array(2) {
      ["type"]=>
      string(5) "skype"
      ["value"]=>
      string(10) "checkmeout"
    }
  }

即时通讯帐户、联系信息、电子邮件地址等信息。。。我找不到他们!!这些信息不会显示给任何人!为什么?!我的意思是我应该能够访问我的帐户,获取信息并向人们展示,不是吗?!那么不可能得到其他信息吗?!我只得到了我的墓穴名称和我的头像。它在电子邮件中起作用。我将尝试创建一个AIM帐户:D我确实将它标记为一个答案。