2

如果您的服务器仅支持 Apache,那么除了 PHP 之外,您还可以使用哪些服务器端脚本语言?

4

4 回答 4

4

If I understand your question correctly, you have a Apache + PHP server that you can upload code to and you can install Lisp etc on, but you can't reconfigure Apache?

The best answer would really be to talk to whoever controls your server and get them to enable the appropriate mods or mod_proxy-ing to whichever language or application you want.

But if this isn't an option, you could implement a reverse proxy in PHP that passes all calls through to your Lisp application.

于 2012-09-23T00:53:03.170 回答
3

Apache 通常在编译时支持模块。PHP 就是这样一个模块,通常在您的apache.conf文件中配置。如果您有权编辑您的 apache.conf,您可以编辑include系统上已经存在的其他模块,或者您添加到系统中的模块。

您可以添加的另一个模块的示例是mod_wsgi,允许您从python文件中提供服务。

您要搜索的是apache modules.

于 2012-09-23T00:54:42.180 回答
2

Apache supports a lot of languages besides PHP, you can check all of them here and how to get it: http://projects.apache.org/indexes/language.html

Most of these language can be supported at the same time, you can install them by using modules or scripts in cgi-bin-

于 2012-09-23T00:53:57.553 回答
1

The Apache feature you were describing before question edit runs PHP files via a module. Another commonly used apache module is CGI, which allows you to use any language, but it's discouraged because of performance and security.

You're better off using FastCGI (which isn't normal CGI) or similar. If you can't make any modifications to the apache config file, you're boned. No non-php auto-evaluating scripts in public_html.

于 2012-09-23T00:51:46.213 回答