ChinaUnix.net
相关文章推荐:

Django Python实战 code

版权声明:可以转载,转载时务必以超链接形式标明文章原始出处和作者信息及版权声明 在与用户的交互过程中,表单发挥了十分重要的作用,多数 Web 应用都带有许多的表单处理。与数据模型类似,如果使用传统的开发方法,那么表单页面的编写和提交结果的验证和处理将成为开发者一大头疼事。 因此,django 中将表单抽象为模型,集表单生成、内容验证为一体。通过视图控制将表单模型、数据模型结合在一起,就可以很容易地实现表单结构的...

by hkebao - Python文档中心 - 2009-08-12 17:34:37 阅读(2110) 回复(0)

相关讨论

http://www.toochange.com 用django开发的一个网站。 物品交易,交换,校园,圈子,同城的web2.0的网站。

by chf99cn - Python - 2006-10-14 16:46:01 阅读(8305) 回复(6)

Compiling python code (maybe tooooooooooold) python source code is automatically compiled into python byte code by the Cpython interpreter. Compiled code is usually stored in PYC (or PYO) files, and is regenerated when the source is updated, or when otherwise necessary. To distribute a program to people who already have python installed, you can ship either the PY files or the PYC files. ...

by liuake - Python文档中心 - 2008-09-10 16:25:41 阅读(1349) 回复(0)

django写一个往打印机里面写东西的程序, 需要往打印机里面写gb2312编码的中文和英文还有数字 在python中已经能打印,但是中文为乱马,在django中因为编码问题一直报错. 谢谢:) 代码如下: import os a = '你好python' c = "echo %s > /dev/usb/lp0" % a os.system(c) django中: import os from django.http import HttpResponse def print_it(request): if request.POST: a = request.POST['pstr'] c =...

by fentin - Python - 2008-07-28 20:05:35 阅读(2294) 回复(3)

一.安装Apache 下载地址: http://httpd.apache.org/ apache_2.2.3-win32-x86-no_ssl.msi 二、安装mod_python 下载地址: http://www.modpython.org/ mod_python-3.3.1.win32-py2.5-Apache2.2.exe 注:python用的是2.5的,安装目录为D:\Web2.0\python25 三、安装django 下载地址:http://code.djangoproject.com D:\Web2.0\django-0.96.1>python setup.py install 安装完后,检查D:\Web2.0\python25\Scripts\django-admin....

by peitomb - Python文档中心 - 2008-04-26 22:06:54 阅读(1769) 回复(0)

环境 winxp +apache2.2.6 mod_python3.3.1 python25 django0.96 下载了limodou的django step by step 的例子newtest 访问http://127.0.0.1:8888/ OK http://127.0.0.1:8888/add ok http://127.0.0.1:8888/wiki ok http://127.0.0.1:8888/address 有问题 http://127.0.0.1:8888/admin 的错误也类似 wiki 也使用了模板,可以找到,address就找不到 httpd-vhosts.conf Listen 127.0.0.1:8888

by yuwang007 - Python - 2007-10-19 10:06:34 阅读(5404) 回复(9)

我在apache中配置的虚拟主机如下: LoadModule python_module modules/mod_python.so Listen 8888 NameVirtualHost 127.0.0.1:8888 DocumentRoot "D:/python25/Lib/site-packages/django/bin/mysite" ServerName localhost:8888 SetHandler python-program pythonPath "['D:/python25/Lib/site-packages/django/bin/']+sys.path" pythonHandler ...

by pgt112you - Python - 2009-04-10 20:19:30 阅读(2279) 回复(3)

本文转自: http://allo.ave7.net/django_with_mod_python django 是经常与Rails相提并论的python Web框架。但别的姑且不说,django的环境搭建实在是不够亲切,简单的搭建过程中被雷到多次,特记录如下以供备忘。 安装django 确保在django安装之前已经安好了pythondjango的最新Source可以从SVN获得: http://code.djangoproject.com/svn/django/trunk/ 然后执行django的setup.py python setup.py install python setup.py i...

by linxh - Python文档中心 - 2009-03-16 10:04:33 阅读(1708) 回复(0)

部署环境 windows xp sp3    (ip:192.168.0.5) appserv  目录为 d:\appserv 项目目录为 d:\my4 1.安装AppServ 2.5.10  (包括了Apache 2.2.8   + PHP 5.2.6  + MySQL 5.0.51b + phpMyAdmin-2.10.3) http://prdownloads.sourceforge.net/appserv/appserv-win32-2.5.10.exe?download 2.安装python2.5 http://www.python.org/ftp/python/2.5.4/python-2.5.4.msi 3.安装 django ...

by miocn - Python - 2009-03-10 21:54:37 阅读(3943) 回复(8)

LoadModule python_module /usr/lib/apache2/modules/mod_python.so | V pythonHandler django.core.handlers.modpython | V SetEnv django_SETTINGS_MODULE | V django.conf.settings | V settings.py 本文来自ChinaUnix博客,如果查看原文请点:http://blog.chinaunix.net/u/19962/showart_241678.html

by unixlanser - Python文档中心 - 2007-02-01 22:39:09 阅读(1149) 回复(0)

http://hideto.javaeye.com/blog/41789 django自带的服务器不是很好,改成Apache+mod_python的方式写一个HelloWorld。 一、安装Apache apache_2.2.4-win32-x86-no_ssl.msi安装很方便。能否启动与http.conf文件的配置有关系。 二、安装mod_python mod_python-3.3.0b.win32-py2.4-Apache2.2.exe点击安装即可。注意对应的python与Apache版本。 三、配置http.conf 1、 MaxRequestsPerChild 1,这样可以在开发阶段不用重启Apache进行测...

by MotsQueen - Python文档中心 - 2007-01-18 20:10:13 阅读(1145) 回复(0)