Created
November 6, 2009 13:18
-
-
Save eliaskg/227982 to your computer and use it in GitHub Desktop.
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
- (void)searchYoutube:(id)sender | |
{ | |
var query = encodeURI([sender objectValue]); | |
var request = [CPURLRequest requestWithURL:"http://gdata.youtube.com/feeds/api/videos?alt=json-in-script&callback=callback&q=" + query]; | |
var connection = [CPJSONPConnection sendRequest:request callback:"callback" delegate:self]; | |
} | |
- (void)connection:(CPJSONPConnection)aConnection didReceiveData:(CPString)data | |
{ | |
[self showSearchResults:data]; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment