I just started learning Dojo. I followed one example of Widget on a site with several ways to load Dojo libraries. I like to use the AOL link to download Dojo.js as follows:
<script type="text/javascript"
src="http://o.aolcdn.com/dojo/1.2.0/dojo/dojo.xd.js">
</script>
and saved my widget codes on a local web server as follows:
scripts/
myWidget/
widgetExample.js
...
test.html
where widgetExample.js contains my widget class codes, and test.html is my testing page. The error message I received is: "uncaught exception: Failed to load cross-domain resources: myWidget.widgetExample ...". I'm not sure if I should download the Dojo package locally? I really like to share the Dojo library package, since they are loaded from or loaded from AOL, and only put my own codes in the local path. I tried google about various domain downloads, baseScriptUrl and moduleMapping? Still unable to understand. Thanks for any detailed instructions, if any.
source
share