我想在ASP程序中加一个计数器,但不知加到那里,请教一下各位

来源:百度知道 编辑:UC知道 时间:2024/05/27 17:19:49
<!-- #include file="include/conn.asp" -->
<!-- #include file="include/vars.asp" -->
<!-- #include file="include/asptemplate.asp" -->
<!-- #include file="zm_main.asp" -->
<!-- #include file="zm_default.asp" -->
<%
'on error resume next
dim t
set t = New ASPTemplate
t.SetTemplatesDir(c_tmp)
t.SetTemplateFile "default.html"

t.SetVariableFile "header", "header.html"
t.SetVariableFile "footer", "footer.html"

t.SetVariable "c_tmp",c_tmp
t.SetVariable "c_logo","./UpLoadfiles/upLoadImages/"&c_logo
t.SetVariable "c_name",c_name
t.SetVariable "mainnav",mainnav
t.SetVariable "productmenu",productmenu
t.SetVariable "newslist",newslist
t.SetVariable "productlist"

application 在global.asa中的onsessionstart事件中加入+1就行了。计数器一般的方法就是这样。当然也有其它的方法

不知道你要计什么数
如果是本页的,随便加什么地方都可以了