• PHP Preg_match lai izvilktu pirmo youtube linku no teksta

    preg_match('#(?:http://)?(?:www\.)?(?:youtube\.com/(?:embed/|v/|watch\?v=)|youtu\.be/)([\w-]+)(?:\S+)?#', $string, $match);


1111111