Re: Django 1.4.3 Error Login

2013-03-01 Thread Russell Keith-Magee
On Sat, Mar 2, 2013 at 12:50 PM, Ana Molf  wrote:

> This function work under dev server but not ander prod
> Technical server contact said me that there are a problem because at SSH
>
>
Hi Ana,

You've posted this message to django-developers -- the mailing list for
people wanting to discuss the development of Django itself. This sort of
question about Django usage should be posted to django-users.

When you do post to django-users, you're going to need to provide a lot
more detail if you want a helpful response. Specifically, you need to
provide the errors that you're seeing, and the details of your production
platform. Saying "This doesn't work in production" tells us nothing about
the errors you're getting, or the differences between your development and
production environments.

Yours,
Russ Magee %-)

-- 
You received this message because you are subscribed to the Google Groups 
"Django developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-developers+unsubscr...@googlegroups.com.
To post to this group, send email to django-developers@googlegroups.com.
Visit this group at http://groups.google.com/group/django-developers?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.




Django 1.4.3 Error Login

2013-03-01 Thread Ana Molf
This function work under dev server but not ander prod 
Technical server contact said me that there are a problem because at SSH

[28/Feb/2013 23:58:04] "GET /login/ HTTP/1.1" 200 15710
[28/Feb/2013 23:58:12] "POST /login/ HTTP/1.1" 500 6965

def login_test(request):
state = "Ingreso de usuarios registrados:"
current_date=datetime.datetime.now()
#ua=request.META('HTTP_USER_AGENT', 'unknown')
ip=request.META['REMOTE_ADDR']
#user=request.user
username = password = ''
if request.POST:
username = request.POST['username']
password = request.POST['password']
user = authenticate(username=username, password=password)
if user is not None and user.is_active:
login(request, user)
state = "You're successfully logged in!"
return render(request, 
'_xxx.html',{'username':username, 'password':password})
else:
state = "Su usuario ha sido desactivado!. Contacte al administrador 
del sitio para recuperar sus credenciales"
return render_to_response('xx.html',locals())
else:
state = "Su usuario o contraseƱa son incorrectos! Contacte al 
administrador del sitio"
return render_to_response('x.html',{'state':state, 'username': 
username,'current_date': current_date, 'ip': ip})

At dev when submit can reach app ok
At prod when submit reply is 500.html

Server: Apache, debian

 at html

Any comment would be great

Thanks

Ana


-- 
You received this message because you are subscribed to the Google Groups 
"Django developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-developers+unsubscr...@googlegroups.com.
To post to this group, send email to django-developers@googlegroups.com.
Visit this group at http://groups.google.com/group/django-developers?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.