jsonp原理

客户端:
<script type="text/javascript">
function test(data) {
alert(data);
}
</script>
<script type="text/javascript" src=http://******.aspx/?callback=funname></script>

服务端:
var fun = Request["callback"];
Response.Write(fun+"(\"hello word\")");
posted @ 2010-05-18 09:32  KID  阅读(251)  评论(0编辑  收藏  举报