I'm trying to use the JQuery code in dashcode, but I have no idea what to put as the datasource, or if I can even use datasource with JQuery. Can anyone help or point to helpful documentation? Thanks for your help, I'm completely new to dashcode and JQuery.
Asked
Active
Viewed 473 times
1 Answers
0
This is not related to jQuery or dashcode, but it may help you:
Create a js file data.js
with a content like:
processData({"who":"Davis"});
Add both SCRIPT tags below to your HTML page:
<html>
<head></head>
<body>
<script>
function processData(data){
alert(data.who);
}
</script>
<script src="data.js"></script>
</body>
</html>
data.js is JSON data wrapped into a function that is available in your page.
This technique to load data from any origin is called JSONP

Mic
- 24,812
- 9
- 57
- 70