I understand Vimeo-API can fetch links of only 100 videos. We have 200+ videos in Vimeo and would like to fetch their links dynamically thru Cron job. Vimeo told us it can do only for 100 videos. Is that true ? is there anyway we can fetch the links of all videos > 100. Any help would be appreciated.
Thanks
Suresh Agrawal
Nope. From the Vimeo API documentation pages, each page of a response can have a maximum of 100 objects/items returned. The only way to get more than that is to make additional requests, specifying the maximum number of objects/items.
https://developer.vimeo.com/api/common-formats#using-the-pagination-parameter
Also, considering each video object can be quite large, you should use the fields parameter to only specify the metadata needed for your application. For instance, if you only need the video link from the response, then your request uri might look like this:
https://api.vimeo.com/me/videos?fields=uri,link&page=1&per_page=100
See the documentation here: https://developer.vimeo.com/api/common-formats#json-filter
Related
I'm embedding a video on my website from YouTube and I want it to loop. To do that I have to use the loop and playlist parameters. I do that and it generates a link like this: https://www.youtube.com/embed/MegurLP8PxI?playlist=MegurLP8PxI&autoplay=1&controls=0&rel=0&enablejsapi=1&start=312&loop=1&widgetid=55. So the loop parameter is set to 1 and the playlist is set to the video id MegurLP8PxI.
The issue is that when I initially load the video it shows the This video is unavailable error. Refreshing the page fixes that but that's not ideal. What makes it hard to understand what's wrong is that this only happens sometimes, seemingly at random. Happens with other videos too.
Another fix that I found is removing the playlist parameter from the url. However than the video will not loop, which I really need it to. Any help would be really appreciated.
I'm trying to get all photos from a defined facebook page.
https://graph.facebook.com/$pageID/albums?fields=photos.limit(30000)
This only gives me up to a hundred when there's thousands on this particular Mobile Uploads album.
30.000 is way too much, API calls usually have a max limit that is a LOT lower.
Use the paging links in the resulting JSON instead, here is an example from the official docs: https://developers.facebook.com/docs/php/howto/example_pagination_basic
On my (non-commercial) website, I wonna have an Youtube Playlist, for some music. That's why I've done an Playlist. But I miss there the option, to give it out a random way. I've read that by adding &shuffle=123 that would be work, but it isn't. So Is there an other way? I have many different ideas, but no one of them looks practicable for that amount of vids, it would be (actually 130, planned are 300-400).
And than there's an other important thing, how can I protect Viewer on my website from the negative things, an iframe is coming with. I mean for Facebook, Twitter an Whatsapp I'm using Shariff, but what options have I in this case?
Thanks a lot in before for yours help.
(And please excuse my bad english, I'm not native speaker)
First, there is no protection on the player except for what you put on it. So you make the Playlist, you know what is in it.
As to "Shuffle" the play list, you can do it in a few steps.
1: Use the PlayListItems call to get a list of all the video ID's.
2: Put them into an array.
3: Then choose your method for "shuffle" the array ( like PHP shuffle ).
4: Use embedded player to make a new playlist from the re-ordered array list.
Example of a possible embedded playlist using video ID's
<iframe width="480" height="270" src="https://www.youtube.com/embed/NGJrUWWvDWs?playlist=bP_8EYQ-2RA,7oNd6U-qry0,fkHNgGaYR0I,OMOGaugKpzs" frameborder="0" ></iframe>
========================================================================
Help to make an array in php
Info on the function "shuffle"
I want to allow 1 user to point to a youtube video (possibly upload it through the youtube api) on a Drupal site.
And then other users can add videos linked to that video (separate nodes?).
The difficulty is that the videos should be synchronised. So when a user uploads a video to match the original one, he should be able to somehow indicate how this is synchronised with the original one. For instance 4seconds vid1 = 1second vid2
Any ideas, module suggestions, UI ideas are very much appreciated.
I have found this post on video synchronisation with youtube api, but I need a method that would allow the user to actually easily give in the synchronisation. And then synchronise with different starting times.
Best to create a custom module for that. Give the user a form with the youtube id and a sync time then use the youtube api from there. No need for drupal specific code - tho you could create seperate nodes for each video, relate them with node reference fields and store any data in the variables table - butI'd probably create my own table for this.
What is the web technology behind displaying live feeds like twitter search results and dailybooth live feed? Can I get similar results from any RSS with some coding?
The main technology behind such websites often is Ajax. This is used to dynamically change the webpages instead of reloading the whole page.
Yes, you can! You will probably need a realtime (PubSubHubbub-enabled feed) to achieve this, and plug it into some kind of websocket/comet/ajax/longpolling client... but that should work easily. Check this, for example. It's the firehose of gowalla checkins posted to a google map. All the code is on github, so it's quite easy to build, play with!