I apologize. It has nothing to do with document.write (I thought this was the culprit, but it just made it more visible in the browser). I see this double ifr request even if my gadget does NOTHING (other than stub out a default view). Ideas why I would see the ifr request twice?
doug On 10/26/11 1:57 PM, "daviesd" <[email protected]> wrote: > I¹m having something strange happen. If I use document.write in my gadget it > seems to have issues loading > > http://locahost:8080/opensocial/gadgets/ifr?url=... > > It just spins and spins (I see 2 ifr requests one after the other, one > succeeds the other spins the gadget renders but there is an outstanding > network request). > > Here¹s my code > > var params = {}; > params[gadgets.io.RequestParameters.CONTENT_TYPE] = > gadgets.io.ContentType.TEXT; > gadgets.io.makeRequest(url, function(result) { > document.write('gadgets.io: ' + result.errors); > }, params); > > If I remove the document.write or just switch it to an alert it works fine. > > Ideas? > > Doug
