The second method definitely doesn't exist, and you shouldn't plan on
it existing in the future.
You should note that you can now specify the <yt:position> attribute
at insertion time, which might simplify your algorithm a bit. You no
longer have to insert a video at the end of a playlist and then update
its position later. The actual syntax for specifying the initial
position varies depending on which language you're using.
Cheers,
-Jeff Posnick, YouTube API Team
groups.google.com/group/youtube-api-gdata | apiblog.youtube.com |
@YouTubeDev
On Jan 15, 8:56 am, Martti Laine <marttilain...@gmail.com> wrote:
> Hey guys,
>
> I'm building an awesome webapp that heavily involves YouTube playlists.
> Users are able to edit playlist on their own. However, I'm looking for the
> best way to edit the order of the videos. Here are the ways I can think of:
>
> *1. Looping over and over again*
>
> 1. Get the playlist videos.
> 2. Loop through them and remove any that are not in the new playlist
> info and add any that are = after this the playlist has the correct videos.
> 3. Loop through the new playlist info one more time, this time edit the
> videos position with
> $video->editPosition()
>
> *2. An imaginary API method*
>
> 1. Send a simplified list (e.g. an array) of video ID's to the API,
> based on which they whole process would be done automatically.
>
> It would be perfect if the second method existed. If it doesn't, are there
> any other ways or should I use the first method described?
>
> Thanks,
> Martti Laine
--
You received this message because you are subscribed to the Google Groups "YouTube APIs Developer Forum" group.
To post to this group, send email to youtube-api-gdata@googlegroups.com.
To unsubscribe from this group, send email to youtube-api-gdata+unsubscribe@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/youtube-api-gdata?hl=en.
No comments:
Post a Comment