Magic Lu Lujianxy is in gmail.com
Friday May 4 01:05:12 HKT 2007
Http://maowuu.com demonstration site needs to use the components pyisapie, python2.5, vs2005, pywin32, Django 0.96 everyone to download prepared first install python2.5 and pywin32 corresponding version, there is nothing to say here. Click Next as prompted. Then decompress pyisapie and enter source to use vs2005 (this is what I use, 2003 or 6 should be fine) to load python. lib and python. h to re-compile pyisapie. The downloaded pyisapie is compiled using python2.4 by default. Follow the instructions in http://code.djangoproject.com/wiki/djangoonwindowswithiisandsqlserver. When copying pyisapie. dll, use the one compiled by yourself. Finished? Don't worry, you still need to modify the file pyisapie. the first one in Py is to set response = This. GET_RESPONSE (Env. URL, request) to the following response = This. GET_RESPONSE (request) response. path = Env. the URL can be ignored. The response object in the DJ does not have the path attribute. There are no relevant requirements. Then, set # For chunk in http_response.iterator: # Write (chunk) write (http_response.content) OK. You can use it all. Hoho... Hope to help you. Among all the servers in the reminder, the IIS + pyisapie environment is set up above. I have not verified whether this problem exists in other environments. Small reminder (1): Django's URLs. all rules in Py start from accessing the root directory, that is, http: // localhost/. If you use a virtual directory (for example, the virtual directory is Python ), this virtual directory must be included in your rule. All settings in your URLs. py should start with r'python. Small reminder (2): In Django's devolopmentserver, the module loading path will be automatically searched by directory, but it will not be used in IIS. For example, when using Django-tagging, its fields. from tagging in The py module. validators importistaglist can be used in the built-in development server without any problems, but tagging is performed on the server. validators cannot be found. It must be projectname. tagging. validators only