Created
April 13, 2012 03:11
-
-
Save jbristowe/2373309 to your computer and use it in GitHub Desktop.
ListView and Pager Initialization with Remote DataSource (Twitter)
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var dataSource = new kendo.data.DataSource({ | |
transport: { | |
read: { | |
url: "http://search.twitter.com/search.json", | |
contentType: "application/json; charset=utf-8", | |
type: "GET", | |
dataType: "jsonp", | |
data: { | |
q: "#KendoUI" | |
} | |
} | |
}, | |
schema: { | |
data: "results", | |
total: "results_per_page" | |
} | |
}); | |
$("pager").kendoPager({ | |
dataSource: dataSource | |
}); | |
$("#listView").kendoListView({ | |
dataSource: dataSource, | |
pageable: true, | |
template: kendo.template($("#template").html()) | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment