Skip to content

Commit 2329115

Browse files
Add descriptions of remaining HTML files
1 parent 0ac71e3 commit 2329115

1 file changed

Lines changed: 16 additions & 9 deletions

File tree

javascript/README.md

Lines changed: 16 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -23,9 +23,9 @@ Description: This JavaScript sample performs the following functions:<br>
2323
<li>It retrieves the channel name and thumbnail of the authenticated user's channel using the API's channels.list method.</li>
2424
<li>It handles the video upload to YouTube using the resumable upload protocol.</li>
2525
<li>It polls for the uploaded video's upload and processing status using the API's videos.list method by setting the part parameter value to status.</li>
26-
</ol><br>
26+
</ol>
2727

28-
The HTML page uses JQuery, the <code>plusone.js</code> and <code>upload_video.js</code> JavaScript files, and the
28+
The HTML page uses JQuery, the <code>cors_upload.js</code> and <code>upload_video.js</code> JavaScript files, and the
2929
<code>upload_video.css</code> file to upload a video file to YouTube.<br><br>Note that if you use this code in your own application, you must replace the value of the <code>data-clientid</code> attribute in the code for the Sign-In Button
3030
with your project's client ID. The only valid JavaScript origin for the client ID in the sample code is
3131
<code>http://localhost</code>. This means that you could test the sample locally, but it would not work in your
@@ -34,24 +34,31 @@ production application.
3434
### [Retrieve my uploads](/youtube/api-samples/blob/master/javascript/my_uploads.js)
3535

3636
Method: youtube.playlistItems.list<br>
37-
Description: This code sample calls the API's <code>playlistItems.list</code> method to retrieve a list of
38-
videos uploaded to the channel associated with the request. The code also calls the <code>channels.list</code>
39-
method with the <code>mine</code> parameter set to <code>true</code> to retrieve the playlist ID that identifies
40-
the channel's uploaded videos.
37+
Description: The JavaScript sample code performs the following functions:<br>
38+
<ol>
39+
<li>It retrieves the playlist ID for videos uploaded to the user's channel using the API's <code>channels.list</code> method. This API call also sets the <code>mine</code> parameter to <code>true</code> to retrieve channel information for the authorizing user.</li>
40+
<li>It passes that ID to the <code>playlistItems.list</code> method to retrieve the videos in that list.</li>
41+
<li>It displays the list of videos.</li>
42+
<li>It constructs next and previous page buttons and sets their visibility based on the information in the API response.</li>
43+
</ol>
44+
45+
The HTML page below uses JQuery, the <code>auth.js</code> and <code>my_uploads.js</code> JavaScript files, and a CSS file to display the list of uploaded videos.
4146

4247
### [Search by keyword](/youtube/api-samples/blob/master/javascript/search.js)
4348

4449
Method: youtube.search.list<br>
4550
Description: This code sample calls the API's <code>search.list</code> method to retrieve search results associated
46-
with a particular keyword.
51+
with a particular keyword. The HTML page below uses JQuery, along with the auth.js and search.js JavaScript files,
52+
to show a simple search form and display the list of search results.
4753

4854
### [Create a playlist](/youtube/api-samples/blob/master/javascript/playlist_updates.js)
4955

5056
Method: youtube.playlists.insert<br>
51-
Description: This sample creates a private playlist and add videos to it. (You could, of course, modify the code so
52-
that it creates a publicly visible playlist or so that it checks a form value to determine whether the playlist is
57+
Description: This JavaScript code creates a private playlist and adds videos to that playlist. (You could, of course, modify the code so that it creates a publicly visible playlist or so that it checks a form value to determine whether the playlist is
5358
public or private.) Note that you need to update the client ID in the <code>auth.js</code> file to run this code.
5459

60+
The HTML page below uses JQuery, along with the auth.js and playlist_updates.js JavaScript files, to display a simple form for adding videos to the playlist.
61+
5562
### [Calling the Analytics API](/youtube/api-samples/blob/master/javascript/analytics_codelab.js)
5663

5764
Method: youtubeAnalytics.reports.query<br>

0 commit comments

Comments
 (0)