Application("cityurl")=rs("SMT_cityurl")

来源:百度知道 编辑:UC知道 时间:2024/06/08 00:27:02
Application("cityurl")=rs("SMT_cityurl")

cityurl=Application("cityurl")
请问这两句有什么区别?
<!--#include file="ubb.asp"-->
<%If IsObject(contt) = false Then

if Application("citycss")="" then
On Error Resume Next
set contt = Server.CreateObject("ADODB.Connection")
contt.Open conndata
If Err.Number <> 0 Then
Response.write "系统日常维护中!"
Response.End()
end if

set rs=server.createobject("adodb.recordset")
sql="select * from SMT_config"
rs.open sql,contt,1,1
if not rs.eof then
Application("cityurl")=rs("SMT_cityurl")
........
end if
rs.close
contt.close
set contt=nothing
end if
end if

SMT_citytime="now()"
SMT_citydate="date()"
cityurl=Application("cityurl")
ci

Application("cityurl")=rs("SMT_cityurl") 是把你从数据库读取出来的值保存在Application("cityurl")中,在需要这个值得时候,可以随时调用Application("cityurl")就可以了

rs("SMT_cityurl")=Application("cityurl") 就是调用,不过这样用好象不对吧,还没有这样用过!