⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 mpi.func.readme.txt

📁 这个是发送网站push的php程序
💻 TXT
字号:
mpi.inc.php函数说明:1、构造函数PushInitiator()Function Prototype:PushInitiator() -- 初始化时不传递任何参数,采用默认的PPG来发送PushInitiator($ppg_url) -- 传递一个参数,以http://www.ppg.com:port/uri的形式PushInitiator($ppg_ip,$ppg_port,$ppg_url) -- 传递三个参数,分别是PPG IP地址、PPG端口、PPG处理的URL            $strget = "";            // 设置读取超时时间            stream_set_timeout($fp, 5);            // 读 HTTP 头部信息            while(!feof($fp))            {                $ls_Str = fgets($fp,1024);                if( !trim($ls_Str) )                {                    break;                }                $pos = strpos( $ls_Str, ": " );                $sso_headers[ substr($ls_Str,0,$pos) ] = substr($ls_Str,$pos+2);                $stream_status = stream_get_meta_data($fp);                if( $stream_status["timed_out"]==true )                {                    $other_error_info = join( "\n", $sso_headers );                    error_and_exit( "&#x670d;&#x52a1;&#x5668;&#x7e41;&#x5fd9;&#xff0c;&#x8bf7;&#x7a0d;&#x540e;&#x518d;&#x8bd5;&#x3002;." );                }            }            // 按长度读取            if( $sso_headers["Content-Length"] )            {                $strget = fread( $fp, intval($sso_headers["Content-Length"]) );                $stream_status = stream_get_meta_data($fp);                if( $stream_status["timed_out"]==true )                {                    $other_error_info = $strget;                    error_and_exit( "&#x670d;&#x52a1;&#x5668;&#x7e41;&#x5fd9;&#xff0c;&#x8bf7;&#x7a0d;&#x540e;&#x518d;&#x8bd5;&#x3002;.." );                }            }            // 一个字节一个字节的读            else            {                while(!feof($fp))                {                    $ls_Str = fread($fp,1);                    $strget .= $ls_Str;                    if( strstr($strget,"</misc_command>") )                    {                        break;                    }                    $stream_status = stream_get_meta_data($fp);                    if( $stream_status["timed_out"]==true )                    {                        $other_error_info = $strget;                        error_and_exit( "&#x670d;&#x52a1;&#x5668;&#x7e41;&#x5fd9;&#xff0c;&#x8bf7;&#x7a0d;&#x540e;&#x518d;&#x8bd5;&#x3002;..." );                    }                }            }            fclose($fp);

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -