1/** 2 * Name: YouTube Front Video Player; 3 * Version: 0.1; 4 * Author: Skrra<[email protected]>; 5 */ 6$(function(){ 7 var userId = 'machsakai'; 8 var orderBy = 'published'; // 表示é åº 9 var maxResults = '5'; // æå¤§è¡¨ç¤ºä»¶æ° 10 var url = 'http://gdata.youtube.com/feeds/api/videos?author=' + userId; 11 url += '&orderby=' + orderBy; 12 url += '&alt=json'; 13 $.ajax({ 14 url: url, 15 dataType: 'jsonp', 16 success: function(json){ 17 $('.loading').fadeOut(); 18 var items = json.feed.entry; 19 var mostRecentVideoId = items[0].id.$t.split('/')[6]; 20 var frontVideoPlayer = $('#front-video-player'); // 表示ç¨ããã¯ã¹ã®ã»ã¬ã¯ã¿ 21 var embeddingVideo = '<iframe width="560" height="315" src="http://www.youtube.com/embed/' + mostRecentVideoId + '" frameborder="0" allowfullscreen></iframe>'; 22 frontVideoPlayer.append(embeddingVideo); 23 } // success End 24 }); // $.ajax End 25});
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.