Hot answers tagged


Welcome to the wonderful world of cross domain scripting! We do support JSONP, to alleviate this. Just drop jsonp=myMostFavoriteMethod onto any request, and it'll be returned in a wrapper function invocation. See also.


The method I ended up using in SOUP 1.10 is the first one listed above — loading the full question page and stripping it down to match the review interface. Here's the core of the actual code: var injectAnswers = function ( html ) { // kluge: disable script tags; $.parseHTML() would be better, but needs jQuery 1.8+ var $html = $( html.replace(...


Yes, this is a XSS thing. You can use JSONP (all API methods take a jsonp parameter for the callback name) to work around this. Alternatively, you can use one of the Soapi.JS libraries, which handle this for you.

Only top voted, non community-wiki answers of a minimum length are eligible