【问题标题】:Linkedin API Connection IssueLinkedin API 连接问题
【发布时间】:2013-08-09 18:07:02
【问题描述】:
 I am trying to connect with linkedin in the site in chrome browser its showing the error:

阻止来源为“https://platform.linkedin.com”的框架访问来源网站的框架。协议、域和端口必须匹配。

阻止来源为“https://platform.linkedin.com”的框架访问来源网站的框架。请求访问的框架将“document.domain”设置为“linkedin.com”,但被访问的框架没有。两者都必须将“document.domain”设置为相同的值才能允许访问。 代码:

<script type="text/javascript" src="https://platform.linkedin.com/in.js">
    api_key: hjltf4pxjaa3
    scope : r_basicprofile,r_fullprofile,r_network,rw_groups,r_emailaddress,w_messages
    onLoad: onLinkedInLoad
    authorize: false
    credentials_cookie: true
</script>
<script type="text/javascript">

    function onLinkedInAuth(){
        $.blockUI();
        IN.API.Profile("me")
        .fields("id","firstName","lastName","email-address","headline","pictureUrl","location:(name)","industry","positions","current-status","current-status-timestamp","last-modified-timestamp","associations","honors","interests","publications","patents","languages","skills","certifications","educations","courses","three-current-positions","three-past-positions","num-recommenders","recommendations-received","following","date-of-birth","connections","group-memberships")
        .result(displayProfiles);
       }

Please help me out.  Thanks in advance.

【问题讨论】:

  • 您违反了同源政策。
  • 那么如何使它正确..
  • 您使用的实际 API 代码在哪里?
  • @Sikander 如错误消息提示的那样,确保框架和主窗口具有相同的协议+主机+端口组合,或将两者的“document.domain”设置为相同的值。
  • M 在 javascript 中使用 Linkedin API..

标签: php javascript linkedin


【解决方案1】:

我认为这是一个 chrome 问题,请尝试使用 Firefox

【讨论】:

    猜你喜欢
    • 2015-05-20
    • 1970-01-01
    • 2015-10-26
    • 2011-12-22
    • 2015-04-24
    • 1970-01-01
    • 2011-01-20
    • 1970-01-01
    相关资源
    最近更新 更多