<%@Idioma = "vBScript" codePage = "936"%>
<!-#include file = "Conn.asp"->
<!-#include file = "inc/function.asp"->
<! Doctype html public "-// w3c // dtd html 4.01 transitório // pt" "http://www.w3.org/tr/html4/loose.dtd">
<html>
<head>
<title> Documento sem título </title>
<meta http-equiv = "content-type" content = "text/html; charset = gb2312">
<meta http-equiv = "refresch" content = "300; url = role_house.asp">
</head>
<Body>
<%
em erro de erro em seguida
'
Server.scriptTimeout = 999999
'================================================================================
'Função de codificação de caracteres
'=========================================================================
Função bytestobstr (corpo, código)
objStream dim
set objstream = server.createObject ("adodb.stream")
objstream.type = 1
objstream.mode = 3
objstream.open
objstream.write corpo
objstream.Position = 0
objstream.type = 2
objstream.charset = código
Bytestobstr = objStream.readText
objstream.close
definir objstream = nada
Função final
'Busca a posição de ocorrência da sequência de linha em outra string
Função de notícias (WSTR, STRNG)
Nestring de notícias = Instr (lcase (WSTR), lcase (strng))
Se a história de notícias <= 0, então as notícias = len (WSTR)
Função final
'Substitua a função da string
função replacest (ori, str1, str2)
Replacest = reply (ori, str1, str2)
Função final
'=========================================================================
função readxml (url, código, start, termina)
SET OSEND = CreateObject ("Microsoft.xmlHttp")
SourCecode = Osend.open ("Get", URL, FALSE)
Osend.send ()
Readxml = bytestobstr (Osend.Responsebody, código)
start = instrum (readxml, start)
Readxml = mid (readxml, start)
termina = instrum (readxml, extremidades)
Readxml = esquerda (readxml, ends-1)
Função final
Substro da função (corpo, início, termina)
start = instrum (corpo, start)
Substr = médio (corpo, start+len (start) +1)
ENDS = Instr (Substr, Ends)
Substr = esquerda (substr, ends-1)
Função final
Dim GetCont, NewsContent
Dim URL, título
url = http: //www.***.com "'Notícias url knowky.com
getCont = readxml (url, "gb2312", "<tabela class = k20" "," </ table> ")
getCont = regexhtml (getCont)
Dim KeyId, NewsClass, cidade, posição, housetype, nível, área, preço, demostra
Dim contactman, contato
para i = 2 para ubund (getCont)
Response.write (getCont (i) e "__ <br>")
Templink = MID (getCont (i), Instr (getCont (i), "href =" "")+6, Instr (getCont (i), "" OnClick ")-10)