1.如何用Asp判断你的网站的虚拟物理路径 o\6iq
答:使用Mappath方法 [B9 ;?G
< p align="center" >< font size="4" face="Arial" >< b > <1@
(ioPH
The Physical path to this virtual website is: GGnp Pp
< /b >< /font > (V?@?25
< font color="#FF0000" size="6" face="Arial" > Do*n#=
< %= Server.MapPath("\")% > \##5O7/1
< /font >< /p > [uR/M
2.我如何知道使用者所用的浏览器? };S0 G!
答:使用the Request object方法 (Uk,
strBrowser=Request.ServerVariables("HTTP_USER_AGENT") n%$ &=-Fk
If Instr(strBrowser,"MSIE") < > 0 Then [ee30ELn
Response.redirect("ForMSIEOnly.htm") C6QbBo
Else js <Ww$zFW
Response.redirect("ForAll.htm") z~Na-N
End If N:W9},
p2d\ZgWD=)
3.如何计算每天的平均反复访问人数 ZK!A#Jm{
答:解决方法 T20VX 8gX
< % startdate=DateDiff("d",Now,"01/01/1990") R^8{bP
if strdate< 0 then startdate=startdate*-1 ^}>/n. %
avgvpd=Int((usercnt)/startdate) % > zY%. Rq-
显示结果 !buz<h
< % response.write(avgvpd) % > N.hzKq][
that is it.this page have been viewed since November 10,1998 /fwgqFVk
{exrwnIZj
4.如何显示随机图象 *<