[extractor/generic] Extract all soundcloud embeds (Closes #10179)
This commit is contained in:
parent
39eef54cf0
commit
94aae01548
@ -71,6 +71,7 @@ from .vessel import VesselIE
|
|||||||
from .kaltura import KalturaIE
|
from .kaltura import KalturaIE
|
||||||
from .eagleplatform import EaglePlatformIE
|
from .eagleplatform import EaglePlatformIE
|
||||||
from .facebook import FacebookIE
|
from .facebook import FacebookIE
|
||||||
|
from .soundcloud import SoundcloudIE
|
||||||
|
|
||||||
|
|
||||||
class GenericIE(InfoExtractor):
|
class GenericIE(InfoExtractor):
|
||||||
@ -1999,12 +2000,9 @@ class GenericIE(InfoExtractor):
|
|||||||
return self.url_result(myvi_url)
|
return self.url_result(myvi_url)
|
||||||
|
|
||||||
# Look for embedded soundcloud player
|
# Look for embedded soundcloud player
|
||||||
mobj = re.search(
|
soundcloud_urls = SoundcloudIE._extract_urls(webpage)
|
||||||
r'<iframe\s+(?:[a-zA-Z0-9_-]+="[^"]+"\s+)*src="(?P<url>https?://(?:w\.)?soundcloud\.com/player[^"]+)"',
|
if soundcloud_urls:
|
||||||
webpage)
|
return _playlist_from_matches(soundcloud_urls, getter=unescapeHTML, ie=SoundcloudIE.ie_key())
|
||||||
if mobj is not None:
|
|
||||||
url = unescapeHTML(mobj.group('url'))
|
|
||||||
return self.url_result(url)
|
|
||||||
|
|
||||||
# Look for embedded mtvservices player
|
# Look for embedded mtvservices player
|
||||||
mtvservices_url = MTVServicesEmbeddedIE._extract_url(webpage)
|
mtvservices_url = MTVServicesEmbeddedIE._extract_url(webpage)
|
||||||
|
Loading…
Reference in New Issue
Block a user