javascript asp教程第十课--global asa

发布时间:2022-04-17 发布网站:脚本宝典
脚本宝典收集整理的这篇文章主要介绍了javascript asp教程第十课--global asa脚本宝典觉得挺不错的,现在分享给大家,也给大家做个参考。

Global.asa:

First of all, what is a global.asa? IT's an optional script file that holds certain "global" information that you can access through the entire ASP appliciation. The global.asa is a plain text file saved with the .asa extension.

You should only have one global.asa and it should go in your top level directory.

Below is an example global.asa file. Don't try to understand the script just yet. We'll get to the sPEcifics in the next two lessons.

<OBJECT RUNAT=Server SCOPE=Session ID=MyInfo PROGID="MSWC.MyInfo">
</OBJECT>

<SCRIPT RUNAT="Server" LANGUAGE="JavaScript">
function Application_OnStart()
	{
	Application("someVARiableName")="some value"
	}
function Application_OnEnd()
	{
	Application.Contents.RemoveAll()
	}
function Session_OnStart()
	{
	Session.Timeout=15
	}
function Session_OnEnd()
	{
	//Do Nothing
	}
</SCRIPT>

<!-- METADATA TYPE="typelib" 
FILE="C:\Program Files\Common Files\System\ado\msado15.dll" 
-->

List of Can Do's:

There are four things you can do with a global.asa.

1) Object Declarations
2) Application Events
3) Session Events
4) Library Reference.

I don't expect you understand any of that yet. Just remember, there are only a few things we can do with the global.asa. Let's move on to lesson 11.

脚本宝典总结

以上是脚本宝典为你收集整理的javascript asp教程第十课--global asa全部内容,希望文章能够帮你解决javascript asp教程第十课--global asa所遇到的问题。

如果觉得脚本宝典网站内容还不错,欢迎将脚本宝典推荐好友。

本图文内容来源于网友网络收集整理提供,作为学习参考使用,版权属于原作者。
如您有任何意见或建议可联系处理。小编QQ:384754419,请注明来意。
标签:javascript