Lost CSS using Django-registration

2009-05-24 Thread Anthony
I've set up a base.html file that my html templates extend. This base.html loads a style.css that is being served up by my static file server (currently, the django development static file server). * When I load up one of my custom templates (home.html), the CSS stylings are applied to the outpu

Revisit Django trunk and Python 2.6

2009-05-24 Thread Kegan
I am always using Django trunk and Python 2.5.4. And having no problem. I am thinking of switching to Python 2.6 (just to use latest python version). Anyone is already doing this in development? production? Any problem? Thanks. --~--~-~--~~~---~--~~ You received t

Re: What, if any, Apache modules are required to implement Django authentication?

2009-05-24 Thread V
AFAIK there are thousands of ways to combine Apache+Django for authentication. Just to name a few: * no apache, just django: you can define custom authentication methods (or even Basic Auth) with django. See the docs [1] * apache handles authentication using django as the backend. See the docs [2

Re: open flash chart 2 & django

2009-05-24 Thread Bro
The problem is resolved, thank to everyone On 21 mai, 17:09, Bro wrote: > I've just installed python-cjson 1.0.5 available here > :http://pypi.python.org/pypi/python-cjson/1.0.5 > But the problem remains. --~--~-~--~~~---~--~~ You received this message because yo

Euro DjangoCon Videos

2009-05-24 Thread giorgos
Hello to all, Does anybody know if and where will Euro DjangoCon videos be uploaded ?? There are many people out there interested in Django and presentations like these are a great way to get them in... --~--~-~--~~~---~--~~ You received this message because you

getting error with admin logout

2009-05-24 Thread tekion
all, I am getting the following error when trying to logout from the admin page: Exception Type: ValueError Exception Value: invalid literal for int() with base 10: 'admin/logout' I search google and their is a patch for it: http://code.djangoproject.com/ticket/10061 How do I apply the

reset button question

2009-05-24 Thread Bobby Roberts
i'm trying to put a simple reset button on a form but it's not working Why wouldn't a standard html reset button be working? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group

Djangonic?

2009-05-24 Thread Roberto Cea
If an idiomatic Python program is "pythonic", what do you call idiomatic use of Django, "djangonic"? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-us

Re: Djangonic?

2009-05-24 Thread Joshua Partogi
Is that important? :-D On May 25, 12:21 am, Roberto Cea wrote: > If an idiomatic Python program is "pythonic", what do you call > idiomatic use of Django, "djangonic"? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups

Re: Euro DjangoCon Videos

2009-05-24 Thread Joshua Partogi
On May 24, 8:22 pm, giorgos wrote: > Hello to all, > > Does anybody know if and where will Euro DjangoCon videos be > uploaded ?? > > There are many people out there interested in Django and presentations > like these are a great way to get them in... I would be interested too. :-) -- Join Scrum

Re: Admin css being weird

2009-05-24 Thread simonecare...@gmail.com
Yes I have 2 Django version installed. But in the django.fcgi dispatcher I call the my Django Environment. How can I fix this issue? On 23 Mag, 20:49, Ariel Nunez wrote: > Please make sure there isn't another Django version being loaded. > I experienced the same situation when I had copied admin

Re: running django with wsgi over apache

2009-05-24 Thread Gabriel
Sam Chuparkoff escribió: > > Since you are getting an import error and claim this works under a > different environment, the salient difference may be sys.path. Your > problem involves urlconfig, so you should post settings.ROOT_URLCONF > and your urlconfig, and explain where your urls.py file or

Re: use of HttpResponseForbidden(), etc.

2009-05-24 Thread notcourage
I'm accustomed to seeing the browser present an error message instead of a blank page. curl shows a 301: curl -v http://localhost:8000/resources/users999/forbbidenView * About to connect() to localhost port 8000 (#0) * Trying 127.0.0.1... connected * Connected to localhost (127.0.0.1) port 80

Re: use of HttpResponseForbidden(), etc.

2009-05-24 Thread Karen Tracey
On Sun, May 24, 2009 at 11:33 AM, notcourage wrote: > > I'm accustomed to seeing the browser present an error message instead > of a blank page. > > curl shows a 301: > > curl -v http://localhost:8000/resources/users999/forbbidenView > * About to connect() to localhost port 8000 (#0) > * Tryin

Re: Revisit Django trunk and Python 2.6

2009-05-24 Thread Alex Gaynor
On Sun, May 24, 2009 at 2:21 AM, Kegan wrote: > > I am always using Django trunk and Python 2.5.4. And having no > problem. > > I am thinking of switching to Python 2.6 (just to use latest python > version). Anyone is already doing this in development? production? Any > problem? > > Thanks. > > >

Re: getting error with admin logout

2009-05-24 Thread Alex Gaynor
On Sun, May 24, 2009 at 8:23 AM, tekion wrote: > > all, > I am getting the following error when trying to logout from the admin > page: > > Exception Type: ValueError > Exception Value: > > invalid literal for int() with base 10: 'admin/logout' > > I search google and their is a patch for

multi-table inheritance and binding objects

2009-05-24 Thread Viktor
Hi, I have two models, a parent and a child, and would like to extend an already existing parent to have the child attributes as well. I'm likely to miss something obvious, but couldn't find it. class Attendee(models.Model): and class Submission(Attendee): attendee = models.OneToOneField(A

Re: multi-table inheritance and binding objects

2009-05-24 Thread Alex Gaynor
On Sun, May 24, 2009 at 10:53 AM, Viktor wrote: > > Hi, > > I have two models, a parent and a child, and would like to extend an > already existing parent to have the child attributes as well. I'm > likely to miss something obvious, but couldn't find it. > > class Attendee(models.Model): > > and

Re: multi-table inheritance and binding objects

2009-05-24 Thread V
thanks, it's the same problem On May 24, 5:56 pm, Alex Gaynor wrote: > On Sun, May 24, 2009 at 10:53 AM, Viktor wrote: > > > Hi, > > > I have two models, a parent and a child, and would like to extend an > > already existing parent to have the child attributes as well. I'm > > likely to miss so

Re: running django with wsgi over apache

2009-05-24 Thread Gabriel
The problem was with one of the applications 'profile'. It seems it already exists somewhere. I renamed it to userprofile and now it works ok :) > url(r'^profile/', include('profile.urls')), Regards. --~--~-~--~~~---~--~~ You received this message because yo

Re: please provide a html download of the doc

2009-05-24 Thread Nils-Hero
Very much thanks for the download link, MichaelMasklinn (and for the offer, sam), i have uploaded that on my website, where it can be downloaded as zip and tar: http://freiewelt.org/0/django-docs-1.0-html.zip http://freiewelt.org/0/django-docs-1.0-html.tgz Following your instructions does not wo

Re: Lost CSS using Django-registration

2009-05-24 Thread Anthony
One night of good sleep, and I find the error...somehow, the leading '/' was missing from the declaration. thanks! --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send ema

Re: please provide a html download of the doc

2009-05-24 Thread Alex Gaynor
On Sun, May 24, 2009 at 11:53 AM, Nils-Hero wrote: > > Very much thanks for the download link, MichaelMasklinn (and for the > offer, sam), > i have uploaded that on my website, where it can be downloaded as zip > and tar: > > http://freiewelt.org/0/django-docs-1.0-html.zip > http://freiewelt.org/

Re: Expert

2009-05-24 Thread hankie
Michael, can you point out some of the 3rd party apps you're referring to? Thank you! On May 23, 6:05 pm, Michael wrote: > On Sat, May 23, 2009 at 4:35 PM, dr.attas wrote: > > > I like you to plan me a timetable to learn Django from a to z in 3 > > months pleas help me. > > Start with the tut

Re: running django with wsgi over apache

2009-05-24 Thread Sam Chuparkoff
On Sun, 2009-05-24 at 13:27 -0300, Gabriel wrote: > The problem was with one of the applications 'profile'. It seems it > already exists somewhere. Correct, there is a standard python module called profile. $ python Python 2.6.2 (r262:71600, May 7 2009, 21:32:12) [GCC 4.1.2 (Gentoo 4.1.2 p1.0.

Re: Admin css being weird

2009-05-24 Thread Ariel Nunez
On Sun, May 24, 2009 at 10:03 AM, simonecare...@gmail.com < simonecare...@gmail.com> wrote: > > Yes I have 2 Django version installed. > But in the django.fcgi dispatcher I call the my Django Environment. > How can I fix this issue? I usually use it removing the 'other' version from my python pa

Re: reset button question

2009-05-24 Thread Reiner
I can't think of any reason why it shouldn't work, so I think their might be a problem in your code. Could you some snippet of the relevant html code? On May 24, 3:38 pm, Bobby Roberts wrote: > i'm trying to put a simple reset button on a form but it's not > working  Why wouldn't a standard html

Re: Revisit Django trunk and Python 2.6

2009-05-24 Thread Skylar Saveland
On May 24, 3:21 am, Kegan wrote: > I am always using Django trunk and Python 2.5.4. And having no > problem. > > I am thinking of switching to Python 2.6 (just to use latest python > version). Anyone is already doing this in development? production? Any > problem? > > Thanks. 2.6 works for me. -

Re: Expert

2009-05-24 Thread Michael
On Sun, May 24, 2009 at 1:17 PM, hankie wrote: > > Michael, > > can you point out some of the 3rd party apps you're referring to? > > Thank you! > No problem. James Bennet's apps are very well written, documented and tested and are a great place to look for best practices: http://bitbucket.org/u

Re: use of HttpResponseForbidden(), etc.

2009-05-24 Thread notcourage
curl -v http://localhost:8000/resources/users999/forbbidenView/ * About to connect() to localhost port 8000 (#0) * Trying 127.0.0.1... connected * Connected to localhost (127.0.0.1) port 8000 (#0) > GET /resources/users999/forbbidenView/ HTTP/1.1 > User-Agent: curl/7.18.2 (i486-pc-linux-gnu) l

Re: Admin css being weird

2009-05-24 Thread simonecare...@gmail.com
Yes I fixed this problem. I didn't read your reply, but I did exactly what you suggest and then update the media symbolic link to the correct django media admin. Now all works fine. Thanks a lot. Simone. On May 24, 8:03 pm, Ariel Nunez wrote: > On Sun, May 24, 2009 at 10:03 AM, simonecare...@gma

Re: use of HttpResponseForbidden(), etc.

2009-05-24 Thread Karen Tracey
On Sun, May 24, 2009 at 2:10 PM, notcourage wrote: > > curl -v http://localhost:8000/resources/users999/forbbidenView/ > * About to connect() to localhost port 8000 (#0) > * Trying 127.0.0.1... connected > * Connected to localhost (127.0.0.1) port 8000 (#0) > > GET /resources/users999/forbbid

Re: IOError: request data read error (revisited)

2009-05-24 Thread Jeff FW
Thanks for your response. Sorry I didn't respond earlier--been quite busy. I don't know for certain that anyone's seeing a 500 response--I get an e-mail from Django (traceback below) and an error in the Apache logs (below). I've never received an actual error report from a user (and most of my u

Re: Overriding save() method on models to automatically add ManyToMany relationship

2009-05-24 Thread ringemup
I'm encountering this same problem. Did you ever find a solution? On Apr 27, 1:38 pm, Adam Olsen wrote: > On Mon, Apr 27, 2009 at 11:27 AM, Alex Gaynor wrote: > > The issues if the method, it's nonsensical and doesn't correspond to > > anything(you are instantiating models.Model with save as t

Add rel="nofollow" to all outbound links?

2009-05-24 Thread jago
Hi, can I tell Django 0.96 to automatically process all outbound links and add: rel="nofollow" ? Thanks, jago --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email t

Re: Djangonic?

2009-05-24 Thread James Matthews
Yes, DRY. Don't Repeat Yourself. On Sun, May 24, 2009 at 5:28 PM, Joshua Partogi wrote: > > Is that important? :-D > > On May 25, 12:21 am, Roberto Cea wrote: > > If an idiomatic Python program is "pythonic", what do you call > > idiomatic use of Django, "djangonic"? > > > -- http://www.goldw

Re: running django with wsgi over apache

2009-05-24 Thread Graham Dumpleton
On May 25, 3:42 am, Sam Chuparkoff wrote: > On Sun, 2009-05-24 at 13:27 -0300, Gabriel wrote: > > The problem was with one of the applications 'profile'. It seems it > > already exists somewhere. > > Correct, there is a standard python module called profile. > > $ python > Python 2.6.2 (r262:71

regular ole html forms

2009-05-24 Thread Bobby Roberts
hi group. I've run across a situation where I don't really need a django form to capture the data. In fact i'm not sure how it would work anyway. Basically, I have a tabled set of data with a checkbox on each row and I want to be able to select them and submit that to a django view. The form loo

regular ole html forms

2009-05-24 Thread Bobby Roberts
hi group. I've run across a situation where I don't really need a django form to capture the data. In fact i'm not sure how it would work anyway. Basically, I have a tabled set of data with a checkbox on each row and I want to be able to select them and submit that to a django view. The form loo

Problems with excluding user-field from form

2009-05-24 Thread Martin
Hi, I'm struggling with a simple edit-form. My model has a user-FK and authenticated users can 'create' objects of this model with a form. Pretty simple. They should be able to edit these objects later, but of course not change the value of the user-field. So I excluded the 'User'-field in my Mod

Re: Raises Http404 from Middleware?

2009-05-24 Thread ringemup
Hate to bump threads, but this is a major problem -- has anyone found a workaround for this? --~--~-~--~~~---~--~~ 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@goog

Re: Raises Http404 from Middleware?

2009-05-24 Thread ringemup
Finally did it. This is about as inelegant as it gets, but it seems to work. Instead of just raising Http404, you need to both raise it and catch the exception, then pass the exception off to what would normally handle it. try: raise Http4

Re: running django with wsgi over apache

2009-05-24 Thread Gabriel
Sam Chuparkoff escribió: > The reason python found the standard module instead of your 'profile' > module is that you appended your paths to the end of sys.path. If you > had added them to the beginning of the list, python would have found > your 'profile' module instead of the standard one. Examp

Re: running django with wsgi over apache

2009-05-24 Thread Gabriel
Graham Dumpleton escribió: > FWIW, the reason that mod_wsgi documentation uses append() is > specifically so that it will highlight when people use module names > that conflict with standard modules. But then, Django is part of the > problem here in that it allows/encourages people to not use site

Avoiding unnecessary ajax

2009-05-24 Thread Mozey
I'm developing a very simple application which contains objects of things. These objects are categorized, the categories are kept on the side bar. The side bar will be there at all times. In order to avoid having to fetch a list of categories at all of my views. I'm simply populating the list of

Re: regular ole html forms

2009-05-24 Thread Gabriel
Bobby Roberts escribió: > hi group. > > I've run across a situation where I don't really need a django form to > capture the data. In fact i'm not sure how it would work anyway. > Basically, I have a tabled set of data with a checkbox on each row and > I want to be able to select them and submit

Re: Avoiding unnecessary ajax

2009-05-24 Thread Alex Gaynor
On Sun, May 24, 2009 at 5:34 PM, Mozey wrote: > > I'm developing a very simple application which contains objects of > things. These objects are categorized, the categories are kept on the > side bar. The side bar will be there at all times. > > In order to avoid having to fetch a list of categor

Re: Add rel="nofollow" to all outbound links?

2009-05-24 Thread Alex Gaynor
On Sun, May 24, 2009 at 3:53 PM, jago wrote: > > Hi, > > can I tell Django 0.96 to automatically process all outbound links and > add: rel="nofollow" ? > > Thanks, > jago > > > You could write a middleware that does this, but there's nothing in Django itself to do this. Alex -- "I disapprove o

Is there a version of @login_required that requires the user to log in as a specific user?

2009-05-24 Thread Continuation
For example, I have a view edit_profile that edits a user's profile. Obviously I want to make sure that each user can edit his own profile only. So before the profile of user A is being edited by edit_profile, I want to make sure the current user is logged in as user A. Is there a decorator that

Check if value in List inside template..?

2009-05-24 Thread jago
Hi, I use Django 0.96 and wonder if one can check if a value is in a list; {% if value in mylist %} ... {% endif %} --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send

Re: Euro DjangoCon Videos

2009-05-24 Thread Kegan Gan
+1 for the videos to be uploaded :) On May 24, 10:31 pm, Joshua Partogi wrote: > On May 24, 8:22 pm, giorgos wrote:> Hello to all, > > > Does anybody know if and where will Euro DjangoCon > > videos be > uploaded ?? > > There are many people out there interested in > Django and presentations >

Re: Revisit Django trunk and Python 2.6

2009-05-24 Thread Kegan Gan
Thanks! Time for the switch. On May 25, 2:09 am, Skylar Saveland wrote: > On May 24, 3:21 am, Kegan wrote: > > > I am always using Django trunk and Python 2.5.4. And having no > > problem. > > > I am thinking of switching to Python 2.6 (just to use latest python > > version). Anyone is already

Re: Question about django.views.generic.simple.redirect_to

2009-05-24 Thread Russell Keith-Magee
On Sat, May 23, 2009 at 4:56 AM, Nicolas Steinmetz wrote: > > Hi, > > I was thinking about something like the following in urls.py : > >     (r'(?P\w+)', 'django.views.generic.simple.redirect_to', > {'url': Shorturl.objects.get(slug=shortcut).url }), > > But I did not manage to make it work. > >

Re: Revisit Django trunk and Python 2.6

2009-05-24 Thread Sam Kuper
If you need to use mysqldb, you may have problems. At least, I ran into snags last time I tried to use Django trunk with mysqldb and Python 2.6, and dropped back to 2.5.x --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups

Re: Problem with loading fixture in testcase

2009-05-24 Thread Russell Keith-Magee
On Sat, May 23, 2009 at 12:59 AM, Stefan Tunsch wrote: > > Hi! > > I have a fixture in json format, which I want to start using together > with my test cases. > > I have deleted the data I didn't want from my development database and > have dumped the data with the following command: > manage.py

Re: Problems with excluding user-field from form

2009-05-24 Thread Sam Chuparkoff
On May 24, 5:49 pm, Martin wrote: > Hi, > > I'm struggling with a simple edit-form. My model has a user-FK and > authenticated users can 'create' objects of this model with a form. > Pretty simple. They should be able to edit these objects later, but of > course not change the value of the user-f

Re: Expert

2009-05-24 Thread Kegan Gan
Dr.Attas, I have done this approximately 1 year ago. Took about 3-4 weeks to pick up enough Python, and another 3-4 weeks to be able to write a straight forward Django app. Follow the online tutorial and the Django Book. They are very very good to get started. You *can* write bad Django app, if

Re: Check if value in List inside template..?

2009-05-24 Thread Gabriel
jago escribió: > Hi, > > I use Django 0.96 and wonder if one can check if a value is in a list; > > {% if value in mylist %} > ... > {% endif %} > Not in django itself. You need to write your own tag. Here you have one http://www.djangosnippets.org/snippets/302/ Regards. --~--~-~--~-

Obfuscate HTML..?

2009-05-24 Thread jago
Hi, I want to make the HTML of the website as little human readable as possible. For that I would like to add some layer to Django 0.96 which when writing out the page takes the HTML and adds some processing. 1. How would I obfuscate the HTML as much as possible (remove all line breaks, etc.) 2.

Re: Obfuscate HTML..?

2009-05-24 Thread Alex Gaynor
On Sun, May 24, 2009 at 8:40 PM, jago wrote: > > Hi, > > I want to make the HTML of the website as little human readable as > possible. For that I would like to add some layer to Django 0.96 which > when writing out the page takes the HTML and adds some processing. > > 1. How would I obfuscate th

Re: Obfuscate HTML..?

2009-05-24 Thread David Zhou
On Sun, May 24, 2009 at 9:40 PM, jago wrote: > > I want to make the HTML of the website as little human readable as > possible. For that I would like to add some layer to Django 0.96 which > when writing out the page takes the HTML and adds some processing. > > 1. How would I obfuscate the HTML a

Re: Is there a version of @login_required that requires the user to log in as a specific user?

2009-05-24 Thread Brian Neal
On May 24, 6:50 pm, Continuation wrote: > For example, I have a view edit_profile that edits a user's profile. > Obviously I want to make sure that each user can edit his own profile > only. > > So before the profile of user A is being edited by edit_profile, I > want to make sure the current use

runserver fails

2009-05-24 Thread Chris DPS
When I execute runserver, I get the following message: Validating models... 0 errors found Django version 1.0.2 final, using settings 'mysite.settings' Development server is running at http://127.0.0.1:8000/ Quit the server with CTRL-BREAK. Error: [Errno 10104] getaddrinfo failed And the server

Re: runserver fails

2009-05-24 Thread David Zhou
Does the following worth in the interactive prompt? >>> import socket >>> socket.getaddrinfo("www.google.com", 80) -- dz On Sun, May 24, 2009 at 10:59 PM, Chris DPS wrote: > > When I execute runserver, I get the following message: > > Validating models... > 0 errors found > > Django version

Re: runserver fails

2009-05-24 Thread Chris DPS
No. I get the same error. I tried that on 3 versions of python with the same result. On May 24, 8:03 pm, David Zhou wrote: > Does the following worth in the interactive prompt? > > >>> import socket > >>> socket.getaddrinfo("www.google.com", 80) > > -- dz > > On Sun, May 24, 2009 at 10:59 PM, Ch

HttpResponseRedirect problem

2009-05-24 Thread laspal
Hi, I have a form with 2 buttons. depending on the button click user is taken to different url. view function is : friend_id = request.POST.get('selected_friend_id_list') history = request.POST.get('statushistory') if history: print "dfgdfgdf" return HttpResponseRedir