set x=server.createObject("Microsoft.XMLHTTP")
x.open "get","http://www.baidu.com",false
x.send
dim str
str = x.responseText

解决方案 »

  1.   

       function bin2str(bin)
            dim tmp,ustr
            tmp=""
            for i=1 to LenB(bin)-1
                ustr=AscB(MidB(bin,i,1))
                if ustr>127 then
                    i=i+1
                    tmp=tmp&chr(ustr*256+AscB(MidB(bin,i,1)))
                else
                    tmp=tmp&chr(ustr)
                end if
            next
            bin2str=tmp
        end function
        
        set x=server.createObject("Microsoft.XMLHTTP")
        x.open "get","http://www.webjx.com",false
        x.send
        str=bin2str(x.responseBody)
        response.write "<xmp>"&str&"</xmp>"
        set x=nothing 
    这样可以获取中文
      

  2.   

    看你要用什么方式了,用ASP,PHP,JSP,ASP。NET,都可以。这里给你PHP的代码吧。
    @$fp = fsockopen("hk.finance.yahoo.com",80, $errno, $errstr,60); 
    if (!$fp) { 
      //echo "$errstr ($errno)<br/>\n"; 
    } else { 
      $out = "GET /q?s=0348.HK HTTP/1.1\r\n"; 
      $out .= "Host: hk.finance.yahoo.com \r\n"; 
      $out .= "Connection: Close \r\n\r\n"; 
     
      @fputs($fp, $out); 
      while (!feof($fp)) { 
       $line = fgets ($fp, 1024);
    echo $line."<br>";
    break; 

      } 
      fclose($fp);