百姓网真实电话图片地址PHP版
25121
- ronon2011-10-15高级会员15628
- $contents = file_get_contents('http://chengdu.baixing.com/diannaopeijian/a126971585.html');
- preg_match('/var _ = (.+?)\+0;/is', $contents, $tmp);
- $_ = decode_($tmp[1]);
- preg_match('/code="(.+?)"/is', $contents, $tmp);
- $code = $tmp[1];
- - function decode_($_)
- {
- $_ = str_replace('-~[] 0)
- {
- $d = 0;
- foreach($b as & $a)
- {
- $t = $a+$d*$f;
- $a = intval($t/(1 0)
- {
- array_shift($b);
- }else
- {
- break;
- }
- }
- }
- return $h;
- }
- echo 'http://static.baixing.net/pages/mobile.php?c='.decodeMobile($code,$_).'/3.jpg';复制代码看到论坛里另外两个高手玩的都是PYTHON,小弟献丑,玩玩PHP, 如有BUG,请指出,
由于电话只有0-9组成,做简单的OCR也是很好办的,改天再说吧