Commit 8b00a4b3 authored by Antoine Cellerier's avatar Antoine Cellerier

* dailymotion.lua: woops, forgot to include title fetching in previous version.

parent bea5e7ec
......@@ -15,8 +15,13 @@ function parse()
if not line then break end
if string.match( line, "param name=\"flashvars\" value=\"url=" )
then
return { { url = vlc.decode_uri( string.gsub( line, "^.*param name=\"flashvars\" value=\"url=([^&]*).*$", "%1" ) ) } }
url = vlc.decode_uri( string.gsub( line, "^.*param name=\"flashvars\" value=\"url=([^&]*).*$", "%1" ) )
end
if string.match( line, "<title>" )
then
title = vlc.decode_uri( string.gsub( line, "^.*<title>([^<]*).*$", "%1" ) )
end
if url and title then break end
end
return {}
return { { url = url; title = title } }
end
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment