如何为C ++ CGI脚本配置Apache? [英] How to config apache for C++ CGI scripts?

查看:84
本文介绍了如何为C ++ CGI脚本配置Apache?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我为Perl找到了很多东西,但对于C ++却找不到.我现在正在运行Ubuntu,但是对它没有足够的经验,因此简单的说明非常棒.我刚刚编写了一个作为CGI的小型C ++程序,我需要对其进行测试.谢谢!

I've found a lot of stuff for Perl, but nothing for C++. I'm running Ubuntu right now but I'm fairly inexperienced with it, so simple instructions would be awesome. I've just written a small C++ program made to work as a CGI, and I need to test it out. Thanks!

推荐答案

您不需要做任何特别的事情.只需将其编译为名为*.cgi(或诸如此类)的可执行文件,并确保您拥有

You shouldn't need to do anything special; just compile it to an executable file named *.cgi (or whatnot), and make sure you have

AddHandler cgi-script .cgi

服务器配置中的

(或其他)或.htaccess或其他.

(or whatnot) in your server config or .htaccess or whatnot.

(免责声明:我这样做已经有很多年了,所以我可能会忘记一些东西.但是我认为应该是您所需要的.)

(Disclaimer: It's been many years since I've done that, so I may be forgetting something. But I think that should be all you need.)

这篇关于如何为C ++ CGI脚本配置Apache?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆