Get Page and find div contents then display not working

EDIT: this error is caused by my facebook like script, however this script is still not working but without throwing any errors. I am trying to display part of another page, by using $get and .find jquery functions, however it is giving me an error. I would expect to see if I was linking it to an external domain when I am not. Here is my code: var ComponentSrc = "http://localhost/acatalog/8ft_Trampoline_Tent.html"; $.get(ComponentSrc, function(data){ $(this).children('div').html($(data).find('.page-content').html()); }) However when running this from the following url: `http://localhost/acatalog/8ft_Fun_Pink_Trampoline.html` it is giving me this error: `Given URL is not permitted by the application configuration.: One or more of the given URLs is not allowed by the App's settings. It must match the Website URL or Canvas URL, or the domain must be a subdomain of one of the App's domains.` I realize this error would be displayed if I was not linking to the same domain however I am not. Is it because its localhost?
This is not a CORS error, this is a FaceBook API error. Does your page use FaceBook?

以上就是Get Page and find div contents then display not working的详细内容,更多请关注web前端其它相关文章!

赞(0) 打赏
未经允许不得转载:web前端首页 » JavaScript 答疑

评论 抢沙发

  • 昵称 (必填)
  • 邮箱 (必填)
  • 网址

前端开发相关广告投放 更专业 更精准