php - Get youtube download link url_encoded_fmt_stream_map -


i using preg_match_all youtube video links youtube video page, , put them in array, don't result.

preg_match_all('/url_encoded_fmt_stream_map\=(.*)/', $html, $matches); 

is there problem in syntax of first parameter?

thanks

don't use '=', need use ':' instead (if @ souce, see: "url_encoded_fmt_stream_map":)

so can use this:

preg_match('/url_encoded_fmt_stream_map(.*?);/', $html, $matches);    $matches= substr($matches[0], 30, -1);  

here delete last ';' , first '"url_encoded_fmt_stream_map":'.


Comments

Popular posts from this blog

Delphi XE2 Indy10 udp client-server interchange using SendBuffer-ReceiveBuffer -

Qt ActiveX WMI QAxBase::dynamicCallHelper: ItemIndex(int): No such property in -

Enable autocomplete or intellisense in Atom editor for PHP -