- file_name = self._search_regex(
- r"so\.addVariable\('file','(.*?)'\);",
- webpage, 'file name')
- video_url = 'http://vod-flash.u-strasbg.fr:8080/' + file_name
+ video_url = self._search_regex(
+ r'jwplayer\("Player"\).setup\({[^}]*file: "([^"]+)"',
+ webpage, 'video_url')
+ formats = [{'url': video_url}]
+ if video_url.startswith('rtmp://'):
+ rtmp = re.search(r'^(?P<url>rtmp://[^/]+/(?P<app>.+))/(?P<play_path>mp4:.+)$', video_url)
+ formats[0].update({
+ 'app': rtmp.group('app'),
+ 'play_path': rtmp.group('play_path'),
+ })