Re: How to Create Super User account in any Django Website?

2013-10-08 Thread Harjot Mann
On Wed, Oct 9, 2013 at 1:38 AM, Mamarth Briton wrote: > I found many Journalist creating super user account in many Django website. > Does any one know how to create super user account in Django website. Such > tonganoxiemirror.com is a Django site where I want to create a

Re: How to Create Super User account in any Django Website?

2013-10-08 Thread Russell Keith-Magee
Hi Mamarth, Put it this way -- if you're already an admin user, the answer will be pretty obvious. If you're not an admin user, you can't -- and that's by design. Creating a super user account in Django is just a matter of flicking the "superuser" flag on an existing user's account -- however,

Re: __unicode__() addition not working in basic poll application.

2013-10-08 Thread Brachamul
Could someone post what the entire "models.py" file should look like at this point? I don't think I have indendation problems, but I'm new to both Python & Django, so I can't be sure. Using Python 2.7.5 and Django 1.4. -- You received this message because you are subscribed to the Google

How to Create Super User account in any Django Website?

2013-10-08 Thread Mamarth Briton
Hi, I found many Journalist creating super user account in many Django website. Does any one know how to create super user account in Django website. Such tonganoxiemirror.com is a Django site where I want to create a super user account or a Staff account without support of that site's admin.

Re: Nginx versus Apache

2013-10-08 Thread Mando
+1 nginx+uWSGI On Tuesday, October 8, 2013 7:16:42 AM UTC-5, Andréas Kühne wrote: > > Hi, > > I was wondering, which server would be best for a production environment. > Nginx or apache? At the moment we are running both, nginx for static files > and apache + mod_wsgi for django. But in the

Re: Nginx versus Apache

2013-10-08 Thread Juan Pablo Martínez
+1 nginx+gunicorn On Tue, Oct 8, 2013 at 5:09 PM, Mando wrote: > +1 nginx+uWSGI > > > On Tuesday, October 8, 2013 7:16:42 AM UTC-5, Andréas Kühne wrote: >> >> Hi, >> >> I was wondering, which server would be best for a production environment. >> Nginx or apache? At the

Re: How to Sign In as a admin or Staff in Django Site?

2013-10-08 Thread Andrew Farrell
Hi Mamarth, Follow the directions under "Overview" here: https://docs.djangoproject.com/en/1.6/ref/contrib/admin/, found by googling "django admin site" Create a staff account with the command `manage.py createsuperuser`, and then go to yoursite.com/admin/ (or localhost:8000/admin/) to sign in

Re: Query parameters for receiving post

2013-10-08 Thread Ramiro Morales
On Tue, Oct 8, 2013 at 11:42 AM, Hélio Miranda wrote: > > Hi > Here I am having a problem which is as follows: > I 'm getting parameters via post to make querys depending on paramtros I are > passed ... doing gender filters. > So I'm doing well > def filter(request): > if

Re: How to Sign In as a admin or Staff in Django Site?

2013-10-08 Thread Nigel Legg
See the tutorial in the django documentation. Cheers, Nigel 07914 740972 On 8 October 2013 18:31, Mamarth Briton wrote: > Hi, > > > > How to Sign In as a admin or Staff in Django Site? Dose anybody know about > admin url creation? > > -- > You received this message

Re: How to Query account/profile information for multiple account and allowing user edit or update acount

2013-10-08 Thread Okorie Emmanuel
Thanks for your response This is what i want to do, I want to create an app that have two different users that is teachers(one type of user) and student(another type of user) the problem is how to create them without using AUTH_USER_MODEL = 'myapp.MyUser' since it is for one kind of user only.

Re: PyCons in Africa

2013-10-08 Thread Alex Strickland
On 2013-10-04 06:13 PM, Daniele Procida wrote: First of all, apologies if you have to read this more than once because of the cross-posting. I've had an idea brewing recently. I went to meet Professor Judith Hall this afternoon to talk about it. She's involved with

How to Sign In as a admin or Staff in Django Site?

2013-10-08 Thread Mamarth Briton
Hi, How to Sign In as a admin or Staff in Django Site? Dose anybody know about admin url creation? -- You received this message because you are subscribed to the Google Groups "Django users" group. To unsubscribe from this group and stop receiving emails from it, send an email to

Re: Ho can I reverse urls inside urls.py?

2013-10-08 Thread Bill Freeman
The problem is that reverse works by querying the structure that is defined by importing the urls modules. A possible cheap trick is to create your dictionary in a module global, passing that to the url call, in which case you could later import the module and patch the "post_reset_redirect' item

Re: Ho can I reverse urls inside urls.py?

2013-10-08 Thread Tom Evans
On Tue, Oct 8, 2013 at 4:11 PM, DJ-Tom wrote: > Based on this article I implemented a password reset function. > > Unfortunately, currently this only works on the development server because > the base URLs for the post_reset_redirect are different on the production > server.

Ho can I reverse urls inside urls.py?

2013-10-08 Thread DJ-Tom
Based on this articleI implemented a password reset function. Unfortunately, currently this only works on the development server because the base URLs for the post_reset_redirect are different on the production

Query parameters for receiving post

2013-10-08 Thread Hélio Miranda
Hi Here I am having a problem which is as follows: I 'm getting parameters via post to make querys depending on paramtros I are passed ... doing gender filters. So I'm doing well *def filter(request):* *if request.method == 'POST':* *namepost = request.POST.get('name')* *

Re: Nginx versus Apache

2013-10-08 Thread Vernon D. Cole
If you are doing any of the hundred-odd things that Apache can do an Nginx cannot, then you will need to use Apache. But, if all you are doing is serving static files and handing all heavy lifting to django, then Nginx with uWSGI will do everything you need, and will do it with less resources.

Re: Nginx versus Apache

2013-10-08 Thread Victor Manuel Quiñones Victor
+1 Nginx On Tue, Oct 8, 2013 at 10:06 AM, Valder Gallo wrote: > +1 nginx > > > On Tue, Oct 8, 2013 at 9:16 AM, Andreas Kuhne > wrote: > >> Hi, >> >> I was wondering, which server would be best for a production environment. >> Nginx or apache?

Re: django model(s) silently fails to sync to the DB ( for no apparent reason )

2013-10-08 Thread Rene Zelaya
Hey Doug, Any chance you haven't included those models in the INSTALLED_APPS in your settings.py file? Best, Rene On Monday, October 7, 2013 9:40:33 PM UTC-4, Doug S wrote: > > I don't think I'm making a rookie mistake, I've looked over my code > several times. > I've got two pretty simple

Re: Nginx versus Apache

2013-10-08 Thread Valder Gallo
+1 nginx On Tue, Oct 8, 2013 at 9:16 AM, Andreas Kuhne wrote: > Hi, > > I was wondering, which server would be best for a production environment. > Nginx or apache? At the moment we are running both, nginx for static files > and apache + mod_wsgi for django. But in

Nginx versus Apache

2013-10-08 Thread Andreas Kuhne
Hi, I was wondering, which server would be best for a production environment. Nginx or apache? At the moment we are running both, nginx for static files and apache + mod_wsgi for django. But in the future we will be moving our static assets to S3 and cloudfront, so the reason for using nginx for

Re: Query field with reference

2013-10-08 Thread Hélio Miranda
I managed to solve the problem, I did so: *result = [a.get_json() for a in Player.objects.filter(position__in=Position.objects.filter(name=positionpost))] * Thanks for the trouble -- You received this message because you are subscribed to the Google Groups "Django users" group. To unsubscribe

Re: define BASE_DIR?

2013-10-08 Thread StefanoC
Hello! as much as I understand / agree the point of not using the dev version/doc especially for newbies, I found this https://code.djangoproject.com/ticket/20400 ticket about it that was closed as invalid. Shouldn't this be open and valid instead? Otherwise this doc bug would never get

Re: Query field with reference

2013-10-08 Thread Hélio Miranda
Gives error says: DD is not a valid ObjectId For the DD not objectId of reference -- You received this message because you are subscribed to the Google Groups "Django users" group. To unsubscribe from this group and stop receiving emails from it, send an email to

Re: Query field with reference

2013-10-08 Thread Leonardo Giordani
I do not know MongoDB, so sorry if I get it wrong. I'd say that you have to write *result = [a.get_json() for a in Player.objects.filter(position__position_name='DD')] * since in your attached document you set it this way (line 53). Try and let me know Leo Leonardo Giordani Author of The

Query field with reference

2013-10-08 Thread Hélio Miranda
Hi I was trying to make a query in a field that has refencia to another collection, like this: *result = [a.get_json() for a in Player.objects.filter(position__name='DD')] * But it is returning me empty, and I have a player with the position DD I'm using mongodb as a database. In my Document is