php迅雷的链接算法
$thunder = ("Thunder://QUFodHRwOi8vNjAuMTkxLjYwLjEwODo4MDgwL3hweGlhemFpL0RlZXBpbl9HaG9zdF9YUF9WMTguMC5pc29aWg==");
//解密它
$thunder = trim($thunder,'Thunder://');
$c_thunder = base64_decode($thunder);
$c_thunder = ltrim(rtrim($c_thunder,'ZZ'),'AA');
//out [url]http://60.191.60.108:8080/xpxiazai/Deepin_Ghost_XP_V18.0.iso[/url];
//加密它
$a_link = 'http://60.191.60.108:8080/xpxiazai/Deepin_Ghost_XP_V18.0.iso';
$a_link = sprintf('AA%sZZ',$a_link);
$a_link = sprintf('Thunder://%s',base64_encode($a_link));
//out Thunder://QUFodHRwOi8vNjAuMTkxLjYwLjEwODo4MDgwL3hweGlhemFpL0RlZXBpbl9HaG9zdF9YUF9WMTguMC5pc29aWg== ?>
相关文档:
<?php
class Model_Data_FocusData{
....
public function getData(){...}
}
class Model_Data_IndexData{
....
public function getData(){...}
}
?>
有这么几个类,希望能够自动的根据参数来调用不同的类处理数据。
看调用模块:
<?php
function getData($act){
$class = "Mode ......
小编之前也曾报导过PHP开发人员容易忽略的几点精华,除了一些精华技术方法外,很多细微之处也是程序员
们容易忽略的,下面我们为您总结了10个关于PHP你可能不知道的事情。
关于PHP更多内容,欢迎访问:PHP开发基础入门
1.使用ip2long() 和long2ip()函数来把IP地址转化成整型存储到数据库里。
这种方法把存储 ......
匹配中文字符的正则表达式
: [\u4e00-\u9fa5]
匹配双字节字符(包括汉字在内)
: ["\x00-\xff]
应用:计算字符串的长度
(一个双字节字符长度计2,ASCII字符计1)
String.prototype.len=function(){return
th ......
<?php
//单例模式的类Lock
class
Lock
{
//静态属性$instance
  ......
所需软件源代码包:
httpd-2.2.4.tar.gz mysql-5.0.27.tar.gz php-5.2.1.tar.bz2
freetype-2.3.2.tar.gz gd-2.0.34.tar.gz jpegsrc.v6b.tar.gz
libpng-1.2.8.tar.bz2 libxml2-2.6.24.tar.bz2 zlib-1.2.2.tar.gz
安装顺序:apache -> mysql ......