Fixed download error by adding cookie support
This commit is contained in:
parent
27e3b9ff36
commit
459fe82b8d
@ -29,7 +29,7 @@ function downloadVideo($video_url, $geturl = false)
|
||||
CURLOPT_ENCODING => "utf-8",
|
||||
CURLOPT_AUTOREFERER => true,
|
||||
CURLOPT_COOKIEJAR => 'cookie.txt',
|
||||
CURLOPT_COOKIEFILE => 'cookie.txt',
|
||||
CURLOPT_COOKIEFILE => 'cookie.txt',
|
||||
CURLOPT_REFERER => 'https://www.tiktok.com/',
|
||||
CURLOPT_CONNECTTIMEOUT => 30,
|
||||
CURLOPT_SSL_VERIFYHOST => false,
|
||||
@ -81,7 +81,7 @@ function getContent($url, $geturl = false)
|
||||
CURLOPT_ENCODING => "utf-8",
|
||||
CURLOPT_AUTOREFERER => false,
|
||||
CURLOPT_COOKIEJAR => 'cookie.txt',
|
||||
CURLOPT_COOKIEFILE => 'cookie.txt',
|
||||
CURLOPT_COOKIEFILE => 'cookie.txt',
|
||||
CURLOPT_REFERER => 'https://www.tiktok.com/',
|
||||
CURLOPT_CONNECTTIMEOUT => 30,
|
||||
CURLOPT_SSL_VERIFYHOST => false,
|
||||
@ -122,6 +122,8 @@ function getContent($url, $geturl = false)
|
||||
CURLOPT_USERAGENT => 'Mozilla/5.0 (X11; Ubuntu; Linux i686; rv:28.0) Gecko/20100101 Firefox/28.0',
|
||||
CURLOPT_ENCODING => "utf-8",
|
||||
CURLOPT_AUTOREFERER => false,
|
||||
CURLOPT_COOKIEJAR => 'cookie.txt',
|
||||
CURLOPT_COOKIEFILE => 'cookie.txt',
|
||||
CURLOPT_REFERER => 'https://www.tiktok.com/',
|
||||
CURLOPT_CONNECTTIMEOUT => 30,
|
||||
CURLOPT_SSL_VERIFYHOST => false,
|
||||
|
Loading…
Reference in New Issue
Block a user