Tuesday, February 28, 2012

Re: Going crazy with WSGI

Thanks Javier for the explanation. I've done some more reading, some
things have become clearer, but:

Right now I'm practicing Django by running the Django server
(manage.py runserver) and everything works. Apache also runs but I
have no clue what its doing. If I close the Django server, how do I
run my application? If I save a django.wsgi file in mysite/apache/
django.wsgi will things happen automatically?

When I practiced CGI with python, I had to import the cgi module and
use that to get the inputs from an html form. Do I have to do
something similar with Django?

Thanks again for the help. Appreciate it.

On Feb 28, 10:02 am, Javier Guerra Giraldez <jav...@guerrag.com>
> On Mon, Feb 27, 2012 at 11:19 PM, atlastorm <ays...@gmail.com> wrote:
> > WSGI is a script that connects Django to
> > Apache.
> not really
> WSGI is just a standard, a document that says "the web server will
> call the app as a function with such and such parameters, the app will
> return such and such values with the response"
> armed with that, any Python developer can write a web app just
> following the 'app' part of the standard, and any web server that
> wants to call those apps do the calls following the other part.
> specifically, mod_wsgi is the apache plugin that launches a Python
> interpreter and do all the calls according to the standard, and Django
> is a framework that follows the WSGI standard.
> besides, some WSGI-compliant servers need a little extra information
> to specify exactly what web app to call, and in mod_wsgi case, it's
> done with 'the wsgi file'.  but this is specific to mod_wsgi, other
> servers do that differently.
> --
> Javier

You received this message because you are subscribed to the Google Groups "Django users" group.
To post to this group, send email to django-users@googlegroups.com.
To unsubscribe from this group, send email to django-users+unsubscribe@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/django-users?hl=en.

No comments:

Post a Comment