Warning: file_get_contents(/data/phpspider/zhask/data//catemap/9/delphi/8.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
如何在Apache2.X中为Delphi配置ASAPI DLL?_Delphi_Apache_Dll_Isapi - Fatal编程技术网

如何在Apache2.X中为Delphi配置ASAPI DLL?

如何在Apache2.X中为Delphi配置ASAPI DLL?,delphi,apache,dll,isapi,Delphi,Apache,Dll,Isapi,我试图理解ISAPI是在Apache2.x下运行的。根据我找到的一个教程,我已经使用DelphiXE创建了一个简单的DLL进行测试 我已经将这些行添加到我的apachehttpd.conf文件中 ScriptAlias /Delphi/ "C:/Delphi/bin/" <Directory "C:/Delphi/bin/"> AddHandler isapi-handler .dll AllowOverride None Options ExecCGI Or

我试图理解ISAPI是在Apache2.x下运行的。根据我找到的一个教程,我已经使用DelphiXE创建了一个简单的DLL进行测试

我已经将这些行添加到我的apachehttpd.conf文件中

ScriptAlias /Delphi/ "C:/Delphi/bin/"
<Directory "C:/Delphi/bin/">
  AddHandler isapi-handler .dll    
  AllowOverride None
  Options ExecCGI
  Order allow,deny
  Allow from all
</Directory>
我希望dll只使用默认处理程序:

procedure TWebModule1.WebModule1DefaultHandlerAction(Sender: TObject;
  Request: TWebRequest; Response: TWebResponse; var Handled: Boolean);
  begin
    Response.SendRedirect (Request.Referer);
  end;
问题1:我的具体问题是什么 问题2:有人能给我指一本让基本骨架工作的循序渐进的教程或书吗?在这一点上,我的理解有太多的漏洞


谢谢。

关于这个主题,请看serverfault.com,例如,这个问题:

我使用Apache做了很多工作,但是作为“共享模块”而不是“CGI”模式。您是否尝试过“共享模块”方法?web上是否有“我找到的教程”的链接?此帖子必须移动到ServerFault(在那里它确实是重复的),请参阅我的答案。@M Schenkel教程较旧,返回Delphi 5。非常感谢。我还必须更改重定向到工作的选项。选项ExecCGI+索引
procedure TWebModule1.WebModule1DefaultHandlerAction(Sender: TObject;
  Request: TWebRequest; Response: TWebResponse; var Handled: Boolean);
  begin
    Response.SendRedirect (Request.Referer);
  end;