大家好: 我翻了一下 手册 没有找到 .

解决方案 »

  1.   

    $url="百度"
    $content=file_get_contents($url);
    抓回来后可以用正则配出你想要的
    $sreach="/正则/";
    @preg_match_all($sreach, $content, $matches);
      

  2.   

    file(URL)抓出来是个数组,自己输出看看.判断一下就OK啦...
      

  3.   

    一般做采集都用这个函数.你可以去研究一下dedecms.
      

  4.   


    function GetWebContent($host, $method, $path, $str, $sessid)
    {
        $fp = fsockopen($host, 80);
        if (!$fp) {
            echo "OPEN ERROR";
            return;
        } 
        if ($method == "GET")
            $path .= '?' . $str;
        fputs($fp, "$method $path HTTP/1.1\n");
        fputs($fp, "Host: $host\n");
        if (!empty($sessid)) {
            fputs($fp, "Cookie: $sessid; path=/;\n");
        } 
        fputs($fp, "Content-Type: application/x-www-form-urlencoded\n");
        if ($method == "POST") {
            fputs($fp, "Content-Length: " . strlen($str) . "\n");
        } 
        fputs($fp, "Connection: close\n\n");
        if ($method == "POST") {
            fputs($fp, $str . "\n");
        } while (!feof($fp)) {
            $response .= fgets($fp, 1024);
        } 
        fclose($fp);
        return $response;
    }
      

  5.   

    fopen
    file_get_contents
    curl
    常用点。 
      

  6.   

    file_get_contents/fsockopen等等……
      

  7.   

    file_get_contents
    curl
    都比较好用,当时 curl 需要你的 PHP 安装 curl 组件。