假定 URL 返回一个脚本,该脚本使用相关数据调用指定的回调函数。
getJSON uses the JSONP protocol.
getJSON
Instead of making an XmlHTTPRequest, which cannot cross domains, it makes a <script> tag pointing to a URL in a different domain.The URL is assumed to return a script that calls the specified callback function with the relevant data.
<script>
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
暂无简介
文章 0 评论 0
接受
getJSON
uses the JSONP protocol.Instead of making an XmlHTTPRequest, which cannot cross domains, it makes a
<script>
tag pointing to a URL in a different domain.The URL is assumed to return a script that calls the specified callback function with the relevant data.