Ò׽ؽØÍ¼Èí¼þ¡¢µ¥Îļþ¡¢Ãâ°²×°¡¢´¿ÂÌÉ«¡¢½ö160KB

asp С͵ ²É¼¯ Àà º¯Êý ³£Óà ±ØÐë ½ØÈ¡ ±àÂëת»»

<%
'==================================================
'º¯ÊýÃû£ºGetHttpPage
'×÷ Ó㺻ñÈ¡ÍøÒ³Ô´Âë
'²Î Êý£ºHttpUrl ------ÍøÒ³µØÖ·
'==================================================
Function GetHttpPage(HttpUrl)
If IsNull(HttpUrl)=True or Len(HttpUrl)<18 or HttpUrl="$False$" Then
GetHttpPage="$False$"
Exit Function
End If
Dim Http
Set Http=server.createobject("MSXML2.XMLHTTP")
Http.open "GET",HttpUrl,False
Http.Send()
If Http.Readystate<>4 then
Set Http=Nothing
GetHttpPage="$False$"
Exit function
End if
GetHTTPPage=bytesToBSTR(Http.responseBody,"GB2312")
Set Http=Nothing
If Err.number<>0 then
Err.Clear
End If
End Function
'==================================================
'º¯ÊýÃû£ºBytesToBstr
'×÷ Ó㺽«»ñÈ¡µÄÔ´Âëת»»ÎªÖÐÎÄ
'²Î Êý£ºBody ------Ҫת»»µÄ±äÁ¿
'²Î Êý£ºCset ------Ҫת»»µÄÀàÐÍ
'==================================================
Function BytesToBstr(Body,Cset)
Dim Objstream
Set Objstream = Server.CreateObject("adodb.stream")
objstream.Type = 1
objstream.Mode =3
objstream.Open
objstream.Write body
objstream.Position = 0
objstream.Type = 2
objstream.Charset = Cset
BytesToBstr = objstream.ReadText
objstream.Close
set objstream = nothing
End Function
'==================================================
'º¯ÊýÃû£ºPostHttpPage
'×÷ Ó㺵Ǽ
'==================================================
Function PostHttpPage(RefererUrl,PostUrl,PostData)
Dim xmlHttp
Dim RetStr
Set xmlHttp = CreateObject("Msxml2.XMLHTTP")
xmlHttp.Open "POST", PostUrl, False
XmlHTTP.setRequestHeader "Content-Length",Len(PostData)
xmlHttp.setRequestHeader "Content-Type", "application/x-www-form-urlencoded"
xmlHttp.setRequestHeader "Referer", RefererUrl
xmlHttp.Send PostData
If Err.Number <> 0 Then
Set xmlHttp=Nothing
PostHttpPage = "$False$"
Exit Function
End If
PostHttpPage=bytesToBSTR(xmlHttp.responseBody,"GB2312")
Set xmlHttp = nothing
End Function
'=================================================


Ïà¹ØÎĵµ£º

Asp µ÷ÓÃWebServiceʾÀý

<% '---µ÷ÓÃWebService »ñÈ¡Exchange2007ÒÑÖªÓû§µÄÓʼþδ¶ÁÊý
'---²ÎÊý˵Ã÷----
'url:webservice µÄ·¾¶
'params:·½·¨²ÎÊý
'method:·½·¨Ãû³Æ
'dataType:·µ»ØµÄÊý¾ÝÀàÐÍ
function webServices(url,params,method,dataType)
set objXML=Server.CreateObject("MSXML2.XMLHTTP")
objXML.open "post& ......

asp½ûÖ¹Íⲿ·þÎñÆ÷Ìá½»±íµ¥µ½·þÎñÆ÷

½ûÖ¹Õ¾ÍâÌá½»±íµ¥µÄasp´úÂëÈçÏ£º
<%
server_v1=Cstr(Request.ServerVariables("HTTP_REFERER"))
server_v2=Cstr(Request.ServerVariables("SERVER_NAME"))
if mid(server_v1,8,len(server_v2))<>server_v2 then
response.write "<br><br><center><table border=1 cellpadding=20 bo ......

aspÏÂÔØÆäËüÍøÕ¾µÄͼƬÀ´¸øhtmlÏÔʾ

<%@LANGUAGE="VBSCRIPT" CODEPAGE="936"%>
<%
Option Explicit
Response.Buffer = True '»º´æÍ¼Æ¬
Dim objXMLHTTP, XML
Set XML = Server.CreateObject("Microsoft.XMLHTTP") '½¨Á¢ÏÂÔØ¶ÔÏó
XML.Open "GET","http://www.google.cn/images/nav_logo7.png",False '¿ªÊ¼»ñȡͼƬ,http://xxx/pngÕâ½Ú¿ÉÒԸijÉ× ......

Asp´´½¨Êý¾Ý¿âÎļþ

Sub CreateAccessDB(DBToCreate)
    Dim catNewDB ' As ADOX.Catalog
    Set catNewDB = Server.CreateObject("ADOX.Catalog")
    catNewDB.Create "Provider=Microsoft.Jet.OLEDB.4.0;" & _
        "Data Source=" & se ......

ASPÓïÑÔ»ù´¡Ö®³£Á¿µÄ¶¨Òå·½·¨

±¾ÎÄÁ´½Ó£ºhttp://www.oversteper.com/wprogram/asp/826.html
ASP ¶¨Òå³£Á¿µÄ·½·¨
³£Á¿£ºÓÃÒ»ÖÖÃû³Æ´úÌæÊý×ÖºÍ×Ö·û´®£¬ÇÒÆäÖµ±£³ÖÒ»Ö±²»±ä¡£
ÔÚ VBscript ÖУ¬¿ÉÒÔÓà const Óï¾äÀ´¶¨Òå³£Á¿¡£
³£Á¿·ÖÊý×ÖÐͺÍ×Ö·û´®ÐÍ¡£
±íʾÈÕÆÚµÄ³£Á¿Ð´ÔÚÁ½¸ö # Ö®¼ä¡£
ʾÀý£º
ÒÔÏÂΪÒýÓÃÄÚÈÝ£º
<%@LANGUAGE="VBSCRIPT" CODEPAG ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØÍ¼ | ¸ÓICP±¸09004571ºÅ