ASP¼ò½é
ASPÈ«³ÆΪActive Server Pages£¬ÊÇÒ»ÖÖÓÉ΢Èí(M1crosoft)¹«Ë¾¿ª·¢µÄ·þÎñÆ÷¶Ë½Å±¾ÓïÑÔÔËÐл·¾³£¬Ëü¿ÉÒÔ½áºÏHTMLÓïÑÔºÍActiveX×é¼þ½¨Á¢¶¯Ì¬¡¢½»»¥¡¢¸ßЧµÄWeb·þÎñÆ÷¶ËÓ¦ÓóÌÐò¡£µ±Ò»¸öÓû§ä¯ÀÀÆ÷´Óweb·þÎñÆ÷ÇëÇóÒ»¸öAsPÍøҳʱ£¬web·þÎñÆ÷»á
½«Õâ¸öAsPÎļþ·¢Ë͸øweb·þÎñÆ÷µÄAsPÒýÇ棬AsPÒýÇ潫¸ÃAsPÍøÒ³ÖÐËùÓеķþÎñÆ÷¶Ë½Å±¾(<%ºÍ%>Ö®¼äµÄ´úÂë)½øÐд¦Àí£¬²¢½«
Êä³ö½á¹ûת»»³ÉHTML´úÂ룬Ȼºó½«´¦ÀíºóµÄÍêÕûHTML´úÂë·¢Ë͸øÓû§ä¯ÀÀÆ÷¡£AsP³ÌÐòÖл¹¿ÉÒÔͨ¹ýActiveX Date Object¶ÔÏóʵ
ÏÖ¶ÔÊý¾Ý¿âµÄ·ÃÎÊ´¦Àí¡£
´ÓÈí¼þµÄ¼¼Êõ²ãÃæ¿´£¬AsPÓÐÈçÏÂÌص㡣
(1)ÎÞÐë±àÒë¡£AsP½Å±¾¼¯³ÉÓÚH¶¡MLµ±ÖУ¬ÎÞÐë±àÒë»òÁ´½Ó¼´¿ÉÖ±½Ó½âÊÍÖ´ÐС£
(2)Ò×ÓÚÉú³É¡£¿ÉÒÔʹÓó£¹æÎı¾±à¼Æ÷½øÐÐAsP³ÌÐò´úÂëµÄ±àд£¬Ò²¿ÉÒÔ±ãÓÃ
FrontPageºÍDrcamweaverµÈÍøÒ³ÖÆ×÷¹¤¾ß¡£
(3)¶ÀÁ¢ÓÚä¯ÀÀÆ÷¡£AsP½Å±¾ÔÚÕ¾µã·þÎñÆ÷¶ËÖ´ÐУ¬ÎÞÐëÓû§¶Ë°ÆÀÀÆ÷µÄÖ§³Ö¡£
(4)ÃæÏò¶ÔÏó¡£ÔÚAsP½Å±¾ÖпÉÒÔ·½±ãµØÒýÓÃϵͳ×é¼þºÍAsPµÄÄÚÖÃ×é¼þ£¬»¹ÄÜͨ
¹ý¶¨ÖÆActiveX·þÎñÆ÷×é¼þÀ´À©³ä¹¦ÄÜ¡£
(5)ÓëÈκÎActiveX scriptingÓïÑÔ¼æÈÝ¡£³ýÁË¿ÉʹÓÃVBScriptºÍJavaScriptÓïÑÔ½ø
ÐÐÉè¼ÆÍ⣬»¹¿Éͨ¹ýP1u8—inµÄ·½Ê½£¬Ê¹ÓÃÓɵÚÈý·½ËùÌṩµÄÆäËûscriptingÓïÑÔ¡£
(6)Ô´³ÌÐòÂë²»»áÍâ©¡£ÓÉÓÚAsPÔÚ·þÎñÆ÷¶Ë½âÊÍÖ´ÐУ¬ÔÚ¿Í»§¶ËµÄä¯ÀÀÆ÷ÉÏ¿´µ½
µÄÊÇÖ´ÐкóµÄ½á¹û£¬¿ª·¢ÕßÒ²²»Óõ£ÐıðÈËÏÂÔسÌÐò´úÂ룬Ôö¼ÓÁËÍøÕ¾°²È«ÐÔ¡£
Ïà¹ØÎĵµ£º
<%@ Language=VBScript %>
<SCRIPT id=DebugDirectives runat=server language=javascript>
// Set these to true to enable debugging or tracing
@set @debug=false
@set @trace=false
</SCRIPT>
<HTML>
<HEAD>
<META name=VI60_defaultClientScript content=VBScript>
< ......
<%
set rs=server.createobject("adodb.recordset")
sql="select * from YONGHU where (ID is null)"
rs.open sql,conn,1,3
rs.addnew
rs("USERNAME")=request("username")
rs.update
rs.close
set rs=nothing
conn.close
set conn=nothing
session("username")=rs("name")
respo ......
<%
dim db
set db=Server.CreateObject("Adodb.Connection")
db.Open "Driver={Microsoft Access Driver (*.mdb)};Dbq=" & Server.Mappath("../mdb/count.mdb")
dim strSql,rs,visitNum
strSql="Select visitNum from counter "
SET rs=db.Execute(strSql)
if session("agai ......
×î¼òµ¥µÄ×ö·¨ÊÇÔÚÒ³ÃæµÄ<head></head>±êÇ©ÖмÓÈëÒÔÏ´úÂ룺
<meta http-equiv="Refresh" content="10;url='xxx.asp'">
ÕâÑù¾Í»áÔÚÒ³Ãæ´ò¿ªºó10ÃëÖÓÌøתµ½xxx.aspÁË¡£
Ò²¿ÉÒÔÓÃjavascriptµÄsettimeoutÀ´Íê³É£¬ÔÚÒ³ÃæÖмÓÈëÒÔÏ´úÂ룺
<script language=javascript>
var the_timeout = setTime ......
VBSÀ³¬³öIntegerÀàÐ͵ÄÈ¡Öµ·¶Î§£¬¸ÃÀàÐ͵ÄÈ¡Öµ·¶Î§Îª-32,768 µ½ 32,767 Ö®¼äµÄÕûÊý¡£
³ö´íµÄ¸ùÔ´£º
ÔÚASPÀÓÐʱºòΪÁË·ÂÖ¹×¢È룬ËùÒÔÔÚ½ÓÊÕ²ÎÊýµÄʱºòÖ±½ÓʹÓÃCintº¯Êý°Ñ½Ó¹ýÀ´µÄ²ÎÊýת»»ÎªInteger£¨Êý×Ö£©ÀàÐÍ£¬Õâ¾Í´æÔÚÒ»¸öDZÔÚÎÊÌ⣬µ±Ò³Ãæ½ÓÊÕµÄij¸ö²ÎÊý£¨Request("xxx")£©³¬¹ýÈ¡Öµ·¶Î§Ê±£¨¿É¼òµ¥Àí½âΪ5λÊý×Ö£ ......