public static function get_vimeo_id($input)
    {
        // match: https://vimeo.com/39502360
        if (preg_match('#/vimeo.com/(\d+)#', $input, $matches)) {
            return $matches[1];
        }

        // match: <iframe src="https://player.vimeo.com/video/39502360" width="640" height="480" frameborder="0" ...
        if (preg_match('#/video/(\d+)#', $input, $matches)) {
            return $matches[1];
        }

        return null;
    }