javascript - Pass the youtube video ID to another JS file -
i had check whether url valid youtube video url , youtube video id it, far using simple javascript split function in order achieve this, want pass id javascript file, there youtube palyer , want play video on page.
i have been viewing other stackoverflow threads
i need passes videoid's file executed:
http(s)://www.youtu.be/videoid
http(s)://www.youtube.com/watch?v=videoid (and optionally other short url's script automatically detects whether contains youtube video)
any ideas can handled browser quick/efficient appreciated!
Comments
Post a Comment