Wednesday, 15 May 2013

javascript - Programmatically detect if a web page has embedded a youtube video -


Is it possible to detect programmatically whether a web page has embedded a YouTube video? If so, please give me some directions about writing code.

I am thinking that my function should bring the URL, then check all the elements of the dom (this is probably the part). Then get that YouTube link (if found) whether it is a valid video or not. Is my flow right? Is there a simple / easy implementation?

Thank you!


No comments:

Post a Comment