欧美一级淫片免费视频黄,欧美黄色试片,黄网在线免费观看,国产区一区二,九久久久,九九在线视频,日韩视频1区

龍巖易富通網絡科技有限公司

龍巖小程序開發(fā),龍巖分銷系統

用php連接路由器來執(zhí)行自動重連接ADSL,換ip

2015.09.10 | 707閱讀 | 0條評論 | php

[php] <?php function url($target = '') { $server = '192.168.1.1'; // IP address $host = '192.168.1.1'; // Domain name $port = 80; //端口 $referer = 'http://' . $host . $target; // Referer $username = "root"; #ADSL的路由的用戶名 $password = "routermanage"; #ADSL的路由的管理密碼 $authorization = base64_encode ( $username . ":" . $password ); $File = fsockopen ( $server, $port, $errno, $errstr, 30 ); if ($File) { $out = "GET {$target} HTTP/1.1\r\n"; $out .= "Host: {$host}\r\n"; $out .= "Referer: {$referer}\r\n"; $out .= "Authorization: Basic {$authorization}\r\n"; $out .= "Connection: Close\r\n\r\n"; fputs ( $File, $out ); $makeFile = $buffer = ""; while ( $buffer = fread ( $File, 4096 ) ) { $makeFile = $makeFile . $buffer; } fclose ( $File ); } else exit ( "我靠,不行嗎" ); } url ( "/userRpm/PPPoECfgRpm.htm?Disconnect=斷%20線" ); //這里的路徑根據路由器的不同而變換 echo "已經斷了"; ?> [/php]

贊 (

發(fā)表評論