开发者

How to embed a script so that it acts as a widget?

I have some information in my website which I need to include in my friends website but if I got through script inclusion I will fell into cross domain problem. Currently my website is based on ajax. Any idea or reference to achieve this?

Any 开发者_如何学Pythonhelp will be great!

Thanks,

Karthik


Using ajax you can use something called JSONP

jquery makes it easy - http://api.jquery.com/jQuery.getJSON/


You could either put it in an iframe if it is a stand alone widget, or use flash as a proxy to do the ajax and create a proper cross domain policy for the flash component.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜