简体   繁体   English

获取linkedin资料

[英]get linkedin profile

I am now building new application in which I need to fetch the linkedin profile information of users after successful authentication. 现在,我正在构建新的应用程序,在该应用程序中,需要在成功通过身份验证后获取用户的linkedin配置文件信息。 I have created the following steps as per the document: 我已经根据文档创建了以下步骤:

https://developer.linkedin.com/documents/getting-started-javascript-api

I have put below code in head section - 我已经在下面的代码放在头部分-

 <script type="text/javascript" src="http://platform.linkedin.com/in.js">
          api_key: meufo7vcx8ul
          authorize: true
        </script>

and this into body section, But I'm confused at this part of code: 并进入正文部分,但是我对这部分代码感到困惑:

<script type="in/Login">
    Hello, <?js= firstName ?> <?js= lastName ?>.
</script>

when I am trying to run this page, it gives the syntax error . 当我尝试运行此页面时,它显示syntax error I don't understand where do I get the profile information array. 我不知道从哪里获得个人资料信息数组。

For the error you mentioned, Turn off PHP short open tags. 对于您提到的错误,请关闭PHP短打开标记。 . And for getting profile information: See this link: Linkedin Profile Info sample code. 要获取个人资料信息,请参见:链接: Linkedin个人资料信息示例代码。

Or try: 或尝试:

<script type="in/Login">
Hello, <?php echo '<' . '?js= firstname ?' . '>' ; ?> <?php echo '<' . '?js= lastName ?' . '>' ; ?>.
</script>

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM