没有认真读 apache 官方文档,先自己研究了一下。windows下修改httpd.conf可以用了,做笔记。 添加代码:

LoadModule python_module modules/mod_python.so <Location "/"> SetHandler python-program PythonPath "sys.path+['D:/django']" PythonHandler django.core.handlers.modpython SetEnv DJANGO_SETTINGS_MODULE plant.settings PythonInterpreter plant PythonDebug On </Location>

<Location "/media/"> SetHandler none </Location>

修改代码: DocumentRoot "D:/django/plant" 静态文件路径。 不知道配置是否有问题 ,先做一个小搭建个环境做测试。 看官方文档后再修改。

上一篇:
下一篇:

相关文章:

Categories: 博客记录

0 Responses so far.

Leave a Reply