小辉网络社区致力于优质软件,活动线报,游戏辅助,绿色工具等资源共享,好货不私藏!

火山小视频无水印下载php源码

小辉工作室 其他源码

火山小视频无水印下载php源码,下面就分享关于去除火山无水印去除源码
调用方法: echo huoshan('https://reflow.huoshan.com/hotsoon/s/yOCZCagw700/ ');

<?php
/**
 * 获取火山小视频无水印下载 www.8gws.com
 * @param string $url 火山小视频分享地址
 * @return json
 * @example 调用方法 例: echo huoshan('https://reflow.huoshan.com/hotsoon/s/yOCZCagw700/ ');
 */
public function huoshan($url)
{
    $ch = curl_init($url);
    curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, 0);
    curl_setopt($ch, CURLOPT_SSL_VERIFYHOST, 0);
    curl_setopt($ch, CURLOPT_FOLLOWLOCATION, 1);
    curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
    curl_setopt($ch, CURLOPT_USERAGENT, 'Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/55.0.2883.87 Safari/537.36');
    $content = curl_exec($ch);
    curl_close($ch);
    $pattern = '/"video_id":"(.*?)"/';
    preg_match($pattern, $content, $matches);
    $data_url = 'http://hotsoon.snssdk.com/hotsoon/item/video/_playback/?video_id='.$matches[1];
    $ch = curl_init($data_url);
    curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, 0);
    curl_setopt($ch, CURLOPT_SSL_VERIFYHOST, 0);
    curl_setopt($ch, CURLOPT_FOLLOWLOCATION, 1);
    curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
    curl_setopt($ch, CURLOPT_USERAGENT, 'Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/55.0.2883.87 Safari/537.36');
    curl_exec($ch);
    $newurl = curl_getinfo($ch, CURLINFO_EFFECTIVE_URL);
    curl_close($ch);
    $data = ['code' => 200, 'msg' => '获取成功!', 'download' => $newurl];
    return json_encode($data, JSON_UNESCAPED_UNICODE | JSON_UNESCAPED_SLASHES);
}

温馨提示:如有转载或引用以上内容请将本文链接作为出处标注!百度已收录

免责声明:本站提供的一切软件、教程和内容信息仅限用于学习和研究目的;不得将上述内容用于商业或者非法用途,否则,一切后果请用户自负。本站信息来自网络,版权争议与本站无关。您必须在下载后的24个小时之内,从您的电脑或手机中彻底删除上述内容。如果您喜欢该程序,请支持正版,购买注册,得到更好的正版服务。侵删请致信E-mail:431228450@qq.com

标签 暂无标签
资源分享
评论列表