I have a block of text with tags and garbage in it. Inside this block is a youtube video link i want to get which always starts with (‘http://www.youtube and always ends with ‘,
I am looking for a regular expression that would extract the url. thanks!
this is what i have:
((https?|ftp|file)\://|www.)[A-Za-z0-9\.\-]+(/[A-Za-z0-9\?\&\=;\+!\(\)\*\-\._~%]*)*[^']
You can try this regex…
www.youtube[^']*[^']matches any character except'[^']*matches 0 to many characters except'