Skip to content

Instantly share code, notes, and snippets.

View hungba124's full-sized avatar
💭
god of laziness

Hungpv hungba124

💭
god of laziness
  • Viet Nam
View GitHub Profile

Keybase proof

I hereby claim:

  • I am hungba124 on github.
  • I am hungba124 (https://keybase.io/hungba124) on keybase.
  • I have a public key ASDilDwIa8RzsHeHDahc303vDaIHaRKsJiDHDA8ha8LhMwo

To claim this, I am signing this object:

@hungba124
hungba124 / youtubeID.js
Created May 25, 2017 02:19 — forked from takien/youtubeID.js
Get YouTube ID from various YouTube URL using JavaScript
/**
* Get YouTube ID from various YouTube URL
* @author: takien
* @url: http://takien.com
* For PHP YouTube parser, go here http://takien.com/864
*/
function YouTubeGetID(url){
var ID = '';
url = url.replace(/(>|<)/gi,'').split(/(vi\/|v=|\/v\/|youtu\.be\/|\/embed\/)/);