文档介绍:相信很多朋友有时候会调用一些跨域的 json, 这时候用 就不灵了, 也为我们提供了另一个专门跨域调用的类,, Ext 例子里面的代码: .JS 代码如下 1. // create the Data Store 2. var store = new ({ 3. // load using script tags for cross domain, if the data in on the same domain as 4. // this page, an HttpProxy would be better 5. proxy: new ({ 6. url: '/forum/topics-browse-' 7. }), 8. 9. // create reader that reads the Topic records 10. reader: new ({ 11. root: 'topics' , 12. totalProperty: 'totalCount' , 13. id: 'threadid' , 14. fields: [ 15. 'title' , 'forumtitle' , 'forumid' , 'author' , 16. {name: 'replycount' , type: 'int' }, 17. {name: 'lastpost' , mapping: 'lastpost' , type: 'date' , dateFormat: 'timest amp' }, 18. 'lastposter' , 'excerpt' 19. ] 20. }), 21. 22. // turn on remote sorting 23. remoteSort: true 24. }); 25. ( 'lastpost' , 'desc' ); topics-browse- 1. <?php 2. //Create json 3. $json_data = "......" ; 4. // Grab the callback variable sent with every ScriptTagProxy request 5. $callback = $_REQUEST[ 'callback' ]; 6. // Return the JSON string within the callback function, so ExtJ