Regular Expressions 101

Community Patterns

Community Library Entry

1

Regular Expression
PCRE (PHP <7.3)

/
facebook\.com\/(?:photo.php\?v=|video\/embed\?video_id=|v\/?)(\d+)
/
gi

Description

Matches the video id in FB links

Submitted by Eirenaios - 11 years ago