Re: HTTP POST sent from app to Django Server returns 403 Forbidden
@etone: has this discussion of CSRF enabled you to hunt down your
problem?
Steven.
On Jul 26, 4:30 pm, etone <misplacedcanad...@gmail.com> wrote:
> Hi there,
>
> I'm trying to sent a HTTP POST from a client application to my Django
> app. Django does indeed receive the HTTP POST as I do hit
> _HandleRequest(), however it returns a 403 Forbidden, instead of
> hitting my handler function. I experimented and sent a HTTP GET from
> my client application and in this case I am able to hit my handler
> function. I would like to use HTTP POST as I want to upload some data
> to my Django app.
>
> What am I doing wrong/missing?
>
> Here is my settings.py in my django app:
>
> try:
> from djangoappengine.settings_base import *
> has_djangoappengine = True
> except ImportError:
> has_djangoappengine = False
> DEBUG = True
> TEMPLATE_DEBUG = DEBUG
>
> import os
>
> INSTALLED_APPS = (
> 'djangotoolbox',
> # 'django.contrib.auth',
> 'django.contrib.contenttypes',
> 'django.contrib.sessions',
> )
>
> if has_djangoappengine:
> INSTALLED_APPS = ('djangoappengine',) + INSTALLED_APPS
>
> ADMIN_MEDIA_PREFIX = '/media/admin/'
> MEDIA_ROOT = os.path.join(os.path.dirname(__file__), 'media')
> TEMPLATE_DIRS = (os.path.join(os.path.dirname(__file__),
> 'templates'),)
>
> ROOT_URLCONF = 'urls'
--
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.
0 Comments:
Post a Comment
Subscribe to Post Comments [Atom]
<< Home