weixin_33726318 2012-02-17 12:20 采纳率: 0%
浏览 46

PHP AJAX jQuery跨域

In my web application i've got an iframe from different domain. I wrote some jQuery scripts in iframe that should pass data from iframe to parrent window. But in fact of their are in differents domain I cant do this directly trought JS. So I figured out to send values from iframe to PHP on server 1 then send from server 1 to server 2 data to another PHP file (witch is in another iframe) and then execute PHP function witch fires up a jQuery script with my data.

To send data from iframe I must use AJAX becouse I dont wanna to refresh site while sending it. Everything goes OK, but secound PHP file isn't execute in iframe, but return whole code to AJAX response.

My question is, how can I make secound PHP file to write data to iframe that I set up src= to it?

  • 写回答

1条回答 默认 最新

  • weixin_33737134 2012-02-17 12:26
    关注

    There's a great library for this called easyXDM:

    http://easyxdm.net/wp/

    评论

报告相同问题?

悬赏问题

  • ¥17 pro*C预编译“闪回查询”报错SCN不能识别
  • ¥15 微信会员卡接入微信支付商户号收款
  • ¥15 如何获取烟草零售终端数据
  • ¥15 数学建模招标中位数问题
  • ¥15 phython路径名过长报错 不知道什么问题
  • ¥15 深度学习中模型转换该怎么实现
  • ¥15 Stata外部命令安装问题求帮助!
  • ¥15 从键盘随机输入A-H中的一串字符串,用七段数码管方法进行绘制。提交代码及运行截图。
  • ¥15 TYPCE母转母,插入认方向
  • ¥15 如何用python向钉钉机器人发送可以放大的图片?