Skip to content

Instantly share code, notes, and snippets.

Keybase proof

I hereby claim:

  • I am theclarkster on github.
  • I am chris_clark (https://keybase.io/chris_clark) on keybase.
  • I have a public key ASCri6b5ofQkX72OgCqvyp7WofGE4CELCs7pGjV5NzqD4Ao

To claim this, I am signing this object:

0xbD9538ea0e06E9e9ec9639d8b08f6Dd95A43f2D6
@TheClarkster
TheClarkster / gist:5498710
Created May 1, 2013 21:56
PHP: Regex: Get Youtube ID
preg_match("#.+(youtu\.be\/|youtube\.com\/(watch\?(.*&)?v=|(embed|v|user)\/))([^\?&\"\'>]+)(/|\"|\])?#", $postObj->post_content, $matches)