繁体中文
设为首页
加入收藏
当前位置:ASP技术首页 >> ASP基础 >> 在Apache上运行ASP

在Apache上运行ASP

2006-04-15 08:00:00  作者:  来源:互联网  浏览次数:0  文字大小:【】【】【
简介:大家都以为:ASP只能运行在Windows 98的PWS(Personal Web Server)下,其实不然,在没有PWS的Windows环境下也可以运行,前提条件是你有Apache服务器程序和ASP处理模块。 Apache可以从http://www.apache.org获得,...
关键字:运行 Apache ASP

大家都以为:ASP只能运行在Windows 98的PWS(Personal Web Server)下,其实不然,在没有PWS的Windows环境下也可以运行,前提条件是你有Apache服务器程序和ASP处理模块。

Apache可以从http://www.apache.org获得,ASP处理模块(OpenASP)可以从http://www.activescripting.org/HTML/download.HTML获得。

Open ASP支持Apache 1.3.0 - 1.3.6版本,大家下载时要注意和自己的服务器程序匹配。

其实Open ASP安装很简单,以下是主要步骤:

1. 把下面这行加入到apache/conf/httpd.conf中:

LoadModule ASP_module modules/apASP136.dll

其中modules/是笔者的模块目录,apASP136.dll是笔者所用的版本。

2. 把下面这行加入到apache/conf/mime.types中:

text/x-ASP ASP

这样服务器就可以解释扩展名为.ASP的文件为ASP程序,当然你也可以自己定义扩展名。

此模块不仅可以装在Apache上,还能装在Netscape Server上:

1. In obj.conf

...

Init ...

Init ...

Init fn="load-modules" funcs="ASP-proc" shlib=(path to nsASP.dll)

...

...

Service fn=ASP-proc type=text/x-ASP

Service ...

Service ...

...

2. In mime.types

type=text/x-ASP exts=ASP

这个模块还属于测试版,还有很多地方不完善,对以下方法不支持:

ObjectContext

Request.ClientCertificate

Request.TotalBytes

Request.BinaryRead

Response.CacheControl

Response.Charset

Response.ExpiresAbsolute

Response.IsClientConnected

Response.Pics

Response.Status

Server.ScriptTimeout

Session.CodePage

Session.LCID

Session.StaticObjects

Session_OnEnd

Application.StaticObjects

Application_OnEnd

Standard Base Components

而且现在不提供global.asa。

在OpenASP的主页上你还可以得到它的源代码,这样你可以开发自己需要的ASP模块。

责任编辑:admin
相关文章