Home > Backend Development > PHP Tutorial > PHP generates download link code examples for Thunder, Kuaiche, Tornado and other software_PHP tutorial

PHP generates download link code examples for Thunder, Kuaiche, Tornado and other software_PHP tutorial

WBOY
Release: 2016-07-13 10:29:51
Original
836 people have browsed it

Copy code The code is as follows:

function Download() {
$urlodd= explode('//',$_POST["url"],2);//Divide the link into 2 paragraphs, //The first paragraph is in front, and the second paragraph is in the back.
$head=strtolower($urlodd [0]);//PHP is case-sensitive, convert it to lowercase uniformly first, otherwise HtTp: or ThUNDER: this kind of weird writing method is difficult to deal with
$behind=$urlodd[1];
if ($head=="thunder:"){
$url=substr(base64_decode($behind), 2, -2);//base64 decryption, remove the AA in front and ZZ in the back
}elseif($ head=="flashget:"){
$url1=explode('&',$behind,2);
$url=substr(base64_decode($url1[0]), 10, -10); //base64 decryption, remove the [FLASHGET] before and after
}elseif($head=="qqdl:"){
} $url=base64_decode($behind);//base64 decryption
}elseif( $head=="http:"||$head=="ftp:"||$head=="mms:"||$head=="rtsp:"||$head=="https:"){
        $url=$_POST["url"];//Regular addresses only support http, https, ftp, mms, rtsp transmission protocols, there seem to be very few other places, like XX network disk is actually based on base64, but there are It cannot be downloaded even after it has been decrypted.
}else{
} echo "This page does not support this protocol temporarily";
}
return $url;
}
if($_POST[" url"]!=NULL){
$url=Download($_POST["url"]);
$url_thunder="thunder://".base64_encode("AA".$url."ZZ" );//base64 encryption, the same goes for 2 below
$url_flashget="Flashget://".base64_encode("[FLASHGET]".$url."[FLASHGET]")."&aiyh";
$url_qqdl="qqdl://".base64_encode($url);
}
?>

Please enter a normal link Or Thunder, Express, Tornado chain address:


< ;/form>

Actual address:

Thunder Link:

Express chain:

Tornado chain:

www.bkjia.comtruehttp: //www.bkjia.com/PHPjc/769241.htmlTechArticleCopy the code as follows: ?php function Download() { $urlodd=explode('//',$_POST ["url"],2);//Divide the link into 2 paragraphs, //The first paragraph is in front, and the second paragraph is behind $head=strtolower($u...
Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template