hello i’m building website in which i need the functionality of retriving video ( if video), images, descirption from different links, like different video websites or if general website link get thumbnail and descirption.
is there any php class exist ? for this taks Please help me suggest better solution Thanks in advance…
oh yeah example is just like facebook link tab
Firstly you more than likely referring to video sites such as Youtube and Vimeo.
Both sites have an API Features that you can use to get your video information:
For a extensive frameowrk in youtube api requests you can use Zend Data: http://framework.zend.com/download/gdata
for a Vimeo PHP Library use https://github.com/vimeo/vimeo-php-lib
Most other professional sites will have some sort of API out there, and there would more than likely be libraries for them.
Short answer is no, All there API’s are different, therefore no single class can interact with all the websites successfully.
What you need to do is create a Driver based package to handle this.
You base class would look something like so:
You would then have an interface for your drivers like so:
and each driver would implement the method and extend the request class like so: