0

I try to use a dojo grid in an opensocial gadget, it happens always that the framework try to fetch DataGrid.js from
http://ajax.googleapis.com/ajax/libs/dojo/1.7.2/dojo/../dojox//grid/DataGrid.js, and it fails.

But in a normal html my app works fine and it can fetch DataGrid.js from
http://ajax.googleapis.com/ajax/libs/dojo/1.7.2/dojox//grid/DataGrid.js.

1 Answers1

0

OpenSocial has limited the use of cross-domain requests. I believe the common workaround is to relay via their proxy like so;

<script src="http://api.msappspace.com/proxy/relay.proxy?opensocial_url=http://ajax.googleapis.com/ajax/libs/dojo/1.7.2/dojo/dojo.js" data-dojo-props="async:true"></script>
mschr
  • 8,531
  • 3
  • 21
  • 35
  • it seems doesn't work, and my app can fetch "dojo/store/Memory" in gadget as normal. And when it try to fetch "dojox/grid/DataGrid" the response is 404 The requested URL /ajax/libs/dojo/1.7.2/dojo/../dojox//grid/DataGrid.js was not found on this server. That��s all we know. (http://ajax.googleapis.com/ajax/libs/dojo/1.7.2/dojo/../dojox//grid/DataGrid.js) ---- */ – noodleneedsbeef May 18 '12 at 09:56