HttpResponseRedirect problem
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 HttpResponseRedirect('../status/') else: return direct_to_template(request, 'friends_list.fbml', extra_context={'fbuser': user, 'user_lastname': user_lastname, 'activemaintab': activemaintab, 'friends':friends, 'friend_list': friend_list}) for template : http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Re: runserver fails
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, Chris DPS wrote: > > > 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 athttp://127.0.0.1:8000/ > > Quit the server with CTRL-BREAK. > > Error: [Errno 10104] getaddrinfo failed > > > And the server quits immediately. > > I have been trying to solve this for quite some time now and am really > > desperate for some help. > > I have already tried running it using different ports and running it > > on 0.0.0.0 > > According to Windows, I do not have any Firewalls running, nor do I > > believe there to be any running. > > I can ping localhost fine. > > ping to port 8000 does not get a response > > > What is going on? > > > I have done the exact same python and django installation on two other > > computers (both running Windows) and they worked fine. > > I need this to work on my computer. > > > Please help! > > > Thanks --~--~-~--~~~---~--~~ 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+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Re: runserver fails
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 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 quits immediately. > I have been trying to solve this for quite some time now and am really > desperate for some help. > I have already tried running it using different ports and running it > on 0.0.0.0 > According to Windows, I do not have any Firewalls running, nor do I > believe there to be any running. > I can ping localhost fine. > ping to port 8000 does not get a response > > What is going on? > > I have done the exact same python and django installation on two other > computers (both running Windows) and they worked fine. > I need this to work on my computer. > > Please help! > > Thanks > > > --~--~-~--~~~---~--~~ 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+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
runserver fails
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 quits immediately. I have been trying to solve this for quite some time now and am really desperate for some help. I have already tried running it using different ports and running it on 0.0.0.0 According to Windows, I do not have any Firewalls running, nor do I believe there to be any running. I can ping localhost fine. ping to port 8000 does not get a response What is going on? I have done the exact same python and django installation on two other computers (both running Windows) and they worked fine. I need this to work on my computer. Please help! Thanks --~--~-~--~~~---~--~~ 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+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Re: Is there a version of @login_required that requires the user to log in as a specific user?
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 user is logged in as user A. > > Is there a decorator that can do that? > > Is there a decorator similar to @login_required that requires not only > the user to be logged in, but also that he needs to be logged in as a > specific user (user A in the above example)? Well, typically you don't worry about that. If a user is requesting to edit a profile, you simple pull up that user's profile. --~--~-~--~~~---~--~~ 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+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Re: Obfuscate HTML..?
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 as much as possible (remove all line > breaks, etc.) > 2. How would I best add the layer which does this obfuscation The first question you should ask yourself is "Why?" HTML obfuscation is pretty useless; a simple tidy will reformat HTML back into readable form. Unlike, say, Javascript obfuscation, you're bound by valid HTML elements that cannot be renamed. That said, you use a custom middleware: http://docs.djangoproject.com/en/dev/topics/http/middleware/#process-response The docs for 0.96 is at: http://www.djangoproject.com/documentation/0.96/middleware/#process-response -- dz --~--~-~--~~~---~--~~ 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+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Re: Obfuscate HTML..?
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 the HTML as much as possible (remove all line > breaks, etc.) > 2. How would I best add the layer which does this obfuscation > > > The best way to do the obfuscation would be with middleware, as for how to obfuscate, I don't know. Alex -- "I disapprove of what you say, but I will defend to the death your right to say it." --Voltaire "The people's good is the highest law."--Cicero --~--~-~--~~~---~--~~ 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+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Obfuscate HTML..?
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. How would I best add the layer which does this obfuscation --~--~-~--~~~---~--~~ 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+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Re: Check if value in List inside template..?
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. --~--~-~--~~~---~--~~ 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+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Re: Expert
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 you are not careful. It's important to know the best practices. Watch all the videos from the DjangoCon 2008 at Youtube. Especially Reusable Apps (James Bennett). Hope this helps. On May 25, 2:10 am, Michael wrote: > 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/ubernostrum/He goes by the handle ubernostrum > and has > projects on other sites as well. You can read his blog at b-list.org . He > also gave talks at Pycon and DjangoCon last year about writing reusable apps > that were very cool to > see:http://www.youtube.com/watch?v=A-S0tqpPga4&feature=PlayList&p=D415FAF... > > Another good place to check things out at is the Pinax projects. They are > trying to get a group of regularly used applications all under one simple > project. It is a lot of fun to play with and they are helping to define what > makes a Django app useful.http://pinaxproject.com/ > > Those are just a few examples, just going through django-code and google, > you should be able to find a lot more. > > I hope that helps, > > Michael --~--~-~--~~~---~--~~ 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+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Re: Problems with excluding user-field from form
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-field. So I excluded the > 'User'-field in my ModelForm. I thought when I exclude a field from a > form it just keeps it's value when I call save() on the form. But I > always get this error when trying to save a valid form: > > ' null value in column "User_id" violates not-null constraint ' If you intend your form to save changes to an existing object, you must pass that object in as 'instance' when creating the form. The reference is here: http://docs.djangoproject.com/en/dev/topics/forms/modelforms/#creating-forms-from-models Post your view if you are still having trouble. sdc --~--~-~--~~~---~--~~ 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+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Re: Problem with loading fixture in testcase
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 dumpdata --exclude=contenttypes > myapp/fixtures/inicial.json > > I can also load this data to a fresh database, doing first a syncdb and > then a loaddata command. > > But when I run my testcase, I get the following error: > > > .Problem installing fixture 'inicial.json': Traceback (most recent call > last): > File "C:\django-trunk\django\core\management\commands\loaddata.py", > line 150, > in handle > for obj in objects: > File "C:\django-trunk\django\core\serializers\json.py", line 41, in > Deserializ > er > for obj in PythonDeserializer(simplejson.load(stream)): > File "C:\django-trunk\django\utils\simplejson\__init__.py", line 298, > in load > parse_constant=parse_constant, **kw) > File "C:\django-trunk\django\utils\simplejson\__init__.py", line 338, > in loads > > return _default_decoder.decode(s) > File "C:\django-trunk\django\utils\simplejson\decoder.py", line 326, > in decode > > obj, end = self.raw_decode(s, idx=_w(s, 0).end()) > File "C:\django-trunk\django\utils\simplejson\decoder.py", line 344, > in raw_de > code > raise ValueError("No JSON object could be decoded") > ValueError: No JSON object could be decoded > > The data seems to be loaded correctly to the test database, at least to > some extent. > > How can I track down the error? Or can it be a bug in the deserializer > code... It _could_ be a bug in the deserializer code, but if I had to place a bet, that wouldn't be where I would be looking. There is a fairly extensive set of unit tests for the deserializers, and while I'm sure that they are not infallible, any bugs that remain must be very well hidden. The "No JSON object could be decoded" error generally means that the fixture itself is broken in some way - generally a formatting problem of some kind, such as an extra comma or mismatched parentheses. Of course, this could indicate a problem with the serializer, but without details its hard to narrow this down. I would suggest the following for debug: * Manually inspect the fixture and see if you can find anything obviously un-JSONy. * Try loading the fixture manually (using manage.py loaddata) - this will sometimes give you a little more detail on the location of an error (such as a line number) * Try deleting segments of the fixture until you can get the fixture to load successfully. For example, if the full fixture won't load, try deleting the second half the entries in the fixture. If the fixture gives the same error, then you know the problem is in the first half of the fixture. Repeat until you have reduced the fixture to a single (or small number) of entries that won't load. If you can narrow down the source of the loading problem, we can look into how it occurred, and how to prevent it happening again. Yours, Russ Magee %-) --~--~-~--~~~---~--~~ 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+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Re: Revisit Django trunk and Python 2.6
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 "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+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Re: Question about django.views.generic.simple.redirect_to
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. > > In the meanwhile I did this which works but I'm a little "disappointed" > with this : > > urls.py: > > > from django.conf.urls.defaults import * > from shorturl.views import redirect_to_url > > urlpatterns = patterns('', > (r'(?P\w+)', 'shorturl.views.redirect_to_url'), > ) > > views.py: > - > > from django.http import HttpResponsePermanentRedirect > from atome.shorturl.models import Shorturl > > def redirect_to_url(request, shortcut): > return > HttpResponsePermanentRedirect(Shorturl.objects.get(slug=shortcut).url) > > Any idea ? You could probably genericize your redirect_to_url view a little bit more - you could make the class that is used for lookup configurable, for example - but you have essentially hit on the solution. The issue is that 'shortcut', as captured by the regular expression, isn't a Python variable you can use in the .get() query. As a result, the only way you're going to be able to use shortcut in a query is to push the query into an actual function call - or write a generic view of your own that will perform that function call, based upon a known set of named arguments in the pattern. Yours, Russ Magee %-) --~--~-~--~~~---~--~~ 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+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Re: Revisit Django trunk and Python 2.6
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 doing this in development? production? Any > > problem? > > > Thanks. > > 2.6 works for me. --~--~-~--~~~---~--~~ 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+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Re: Euro DjangoCon Videos
+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 > like these are a great way to get them in... > I would be interested too. :-) > > -- > Join Scrum8.com. > > http://scrum8.com/jpartogi/http://twitter.com/scrum8 --~--~-~--~~~---~--~~ 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+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Check if value in List inside template..?
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 email to django-users@googlegroups.com To unsubscribe from this group, send email to django-users+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Is there a version of @login_required that requires the user to log in as a specific user?
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 can do that? Is there a decorator similar to @login_required that requires not only the user to be logged in, but also that he needs to be logged in as a specific user (user A in the above example)? --~--~-~--~~~---~--~~ 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+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Re: Add rel="nofollow" to all outbound links?
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 of what you say, but I will defend to the death your right to say it." --Voltaire "The people's good is the highest law."--Cicero --~--~-~--~~~---~--~~ 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+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Re: Avoiding unnecessary ajax
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 categories at all of my > views. I'm simply populating the list of categories by ajax. This > seems a bit, clunky to do. Is there a better way to do it? > > > Take a look at template context processors, on inclusion tags. Alex -- "I disapprove of what you say, but I will defend to the death your right to say it." --Voltaire "The people's good is the highest law."--Cicero --~--~-~--~~~---~--~~ 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+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Re: regular ole html forms
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 that to a django view. > The form looks something like this: > > > > > > > > > > Is it possible to take a standard html form as such and then process > it with a django view? I'm reading the form docs and don't see > anything like that. > You can get the values using request.POST.get('fieldname'), in the case of the checkbox use request.POST.getlist('rowid') Regards. --~--~-~--~~~---~--~~ 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+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Avoiding unnecessary ajax
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 categories by ajax. This seems a bit, clunky to do. Is there a better way to do it? --~--~-~--~~~---~--~~ 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+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Re: running django with wsgi over apache
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 name > in package import path. If a package path was always used that > included site name this wouldn't all tend to be a problem and it > wouldn't be necessary to be adding the directory settings.py file is > in to sys.path. Unfortunately people drop the site part of package > import with the thought that it makes reuse of code between sites > easier at some point. > > Graham Yep, thats why I didn't use the project name on my imports. Regards. --~--~-~--~~~---~--~~ 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+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Re: running django with wsgi over apache
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. Example: > > workspace = '/home/gabriel/pywks' > project = '/home/gabriel/pywks/vertaal' > sys.path = [workspace, project] + sys.path > > Hope that makes sense. > I see. Thats the reason it was working with mod_python, because I setted the path that way. I didn't know about the profile module. Anyway, now it works fine :) Thank you! --~--~-~--~~~---~--~~ 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+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Re: Raises Http404 from Middleware?
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 Http404 except: resolver = urlresolvers.RegexURLResolver(r'^/', settings.ROOT_URLCONF) handler = BaseHandler() handler.handle_uncaught_exception(request, resolver, sys.exc_info ()) --~--~-~--~~~---~--~~ 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+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Re: Raises Http404 from Middleware?
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@googlegroups.com To unsubscribe from this group, send email to django-users+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Problems with excluding user-field from form
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 ModelForm. I thought when I exclude a field from a form it just keeps it's value when I call save() on the form. But I always get this error when trying to save a valid form: ' null value in column "User_id" violates not-null constraint ' Is my way of thinking wrong? Adding the User-Field as a hidden field to the form and then doing something like form.User=request.user sounds pretty ugly. Especially when I just want to keep the original value. Regards, Martin --~--~-~--~~~---~--~~ 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+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
regular ole html forms
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 looks something like this: Is it possible to take a standard html form as such and then process it with a django view? I'm reading the form docs and don't see anything like that. --~--~-~--~~~---~--~~ 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+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
regular ole html forms
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 looks something like 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@googlegroups.com To unsubscribe from this group, send email to django-users+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Re: running django with wsgi over apache
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:71600, May 7 2009, 21:32:12) > [GCC 4.1.2 (Gentoo 4.1.2 p1.0.2)] on linux2 > Type "help", "copyright", "credits" or "license" for more information.>>> > import profile.urls > > Traceback (most recent call last): > File "", line 1, in > ImportError: No module named urls > > > > This looks familiar, right? It is not good to name apps to conflict > with standard python modules; someday someone will be confused :). > > 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. Example: > > workspace = '/home/gabriel/pywks' > project = '/home/gabriel/pywks/vertaal' > sys.path = [workspace, project] + sys.path > > Hope that makes sense. 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 name in package import path. If a package path was always used that included site name this wouldn't all tend to be a problem and it wouldn't be necessary to be adding the directory settings.py file is in to sys.path. Unfortunately people drop the site part of package import with the thought that it makes reuse of code between sites easier at some point. Graham --~--~-~--~~~---~--~~ 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+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Re: Djangonic?
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.goldwatches.com --~--~-~--~~~---~--~~ 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+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Add rel="nofollow" to all outbound links?
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 to django-users@googlegroups.com To unsubscribe from this group, send email to django-users+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Re: Overriding save() method on models to automatically add ManyToMany relationship
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 the first > > argument), in Python the correct way to call the parent class's method is: > > > super(MyClass, self).save(*args, **kwargs) > > It was an example, complete with a typo. It should have been: > > def save(self, *args): > models.Model.save(self, *args) > category = Category.objects.all()[0] > self.categories.add(category) > > However, that point is not the problem. Even with the proper syntax, > it doesn't save the ManyToMany relationship. > > -- > Adam Olsen > SendOutCards.comhttp://www.vimtips.orghttp://last.fm/user/synic --~--~-~--~~~---~--~~ 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+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Re: IOError: request data read error (revisited)
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 users aren't the most technically inclined...) so I don't know what they see. I've never been able to duplicate this myself; it happens on average once or twice a week, although it seems to occasionally happen to the same person a couple of times within the span of a few minutes. Also, mod_wsgi is configured in daemon mode, with 1 process and 1 thread, if that matters. I haven't had a chance to try the debugging recipe you provided yet; it's a production site, so I'm rather loathe to mess with it, if I can avoid it. Not to say that I won't try that, if it comes to it. Thanks. Apache log and traceback (both anonymized): [Sat May 16 21:54:10 2009] [error] [client 75.33.xx.xx] (70014)End of file found: mod_wsgi (pid=25650): Unable to get bucket brigade for request., referer: https://domain.com/account/store/178/manage/item/create/ [Sat May 16 17:54:10 2009] [error] [client 75.33.xx.xx] mod_wsgi (pid=18243): Exception occurred processing WSGI script '/var/www/ domain.com/django.wsgi'. [Sat May 16 17:54:10 2009] [error] [client 75.33.xx.xxx] IOError: client connection closed (ignore the time difference--the server is on GMT, but Django is on EST) Traceback (most recent call last): File "/var/lib/python-support/python2.5/django/core/handlers/ base.py", line 86, in get_response response = callback(request, *callback_args, **callback_kwargs) File "/var/www/domain.com/domain/djangologging/decorators.py", line 10, in decorated response = func(*args, **kwargs) File "/var/www/domain.com/domain/store/views.py", line 137, in random_items_ajax if not request.POST or 'count' not in request.POST: File "/var/lib/python-support/python2.5/django/core/handlers/ wsgi.py", line 169, in _get_post self._load_post_and_files() File "/var/lib/python-support/python2.5/django/core/handlers/ wsgi.py", line 149, in _load_post_and_files self._post, self._files = http.QueryDict(self.raw_post_data, encoding=self._encoding), datastructures.MultiValueDict() File "/var/lib/python-support/python2.5/django/core/handlers/ wsgi.py", line 203, in _get_raw_post_data size=content_length) File "/var/lib/python-support/python2.5/django/core/handlers/ wsgi.py", line 69, in safe_copyfileobj buf = fsrc.read(min(length, size)) IOError: request data read error , POST:, COOKIES:{'sessionid': 'xxx'}, META:{'CONTENT_LENGTH': '7', 'CONTENT_TYPE': 'application/x-www-form-urlencoded; charset=UTF-8', 'DOCUMENT_ROOT': '/var/www/domain.com/domain/www', 'GATEWAY_INTERFACE': 'CGI/1.1', 'HTTP_ACCEPT': '*/*', 'HTTP_ACCEPT_ENCODING': 'gzip, deflate', 'HTTP_ACCEPT_LANGUAGE': 'en-us', 'HTTP_CACHE_CONTROL': 'no-cache', 'HTTP_CONNECTION': 'Keep-Alive', 'HTTP_COOKIE': 'sessionid=xxx', 'HTTP_HOST': 'domain.com', 'HTTP_REFERER': 'http://domain.com/page/how_to_sell/', 'HTTP_USER_AGENT': 'Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 6.0; Trident/4.0; SLCC1; .NET CLR 2.0.50727; .NET CLR 3.0.04506; yie8)', 'HTTP_X_REQUESTED_WITH': 'XMLHttpRequest', 'PATH': '/usr/local/bin:/usr/bin:/bin', 'PATH_INFO': u'/ajax/random_items/', 'PATH_TRANSLATED': '/var/www/domain.com/django.wsgi/ajax/ random_items/', 'QUERY_STRING': '', 'REMOTE_ADDR': 'xx.xx.xx.xx', 'REMOTE_PORT': '50355', 'REQUEST_METHOD': 'POST', 'REQUEST_URI': '/ajax/random_items/', 'SCRIPT_FILENAME': '/var/www/domain.com/django.wsgi', 'SCRIPT_NAME': u'', 'SCRIPT_URI': 'http://domain.com/ajax/random_items/', 'SCRIPT_URL': '/ajax/random_items/', 'SERVER_ADDR': 'xx.xx.xx.xx', 'SERVER_ADMIN': '[no address given]', 'SERVER_NAME': 'domain.com', 'SERVER_PORT': '80', 'SERVER_PROTOCOL': 'HTTP/1.1', 'SERVER_SIGNATURE': 'Apache/2.2.9 (Ubuntu) mod_ssl/2.2.9 OpenSSL/0.9.8g mod_wsgi/2.3 Python/2.5.2 Server at domain.com Port 80\n', 'SERVER_SOFTWARE': 'Apache/2.2.9 (Ubuntu) mod_ssl/2.2.9 OpenSSL/ 0.9.8g mod_wsgi/2.3 Python/2.5.2', 'mod_wsgi.application_group': 'domain.com|', 'mod_wsgi.callable_object': 'application', 'mod_wsgi.listener_host': '', 'mod_wsgi.listener_port': '80', 'mod_wsgi.process_group': 'domain.com', 'mod_wsgi.reload_mechanism': '1', 'mod_wsgi.script_reloading': '1', 'wsgi.errors': , 'wsgi.file_wrapper': , 'wsgi.input': , 'wsgi.multiprocess': True, 'wsgi.multithread': False, 'wsgi.run_once': False, 'wsgi.url_scheme': 'http', 'wsgi.version': (1, 0)}> Thanks a lot, Jeff On May 21, 10:47 pm, Graham Dumpleton wrote: > On May 22, 12:31 pm, Jeff FW wrote: > > > > > I've had the same problem, and can't figure out how to resolve it. It > > seems to have nothing to do with the amount of data being transfered: > > it happens occasionally on the smallest of page requests/responses. > > It also doesn't seem to be related to browser, unless several > >
Re: use of HttpResponseForbidden(), etc.
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/forbbidenView/ HTTP/1.1 > > User-Agent: curl/7.18.2 (i486-pc-linux-gnu) libcurl/7.18.2 OpenSSL/0.9.8g > zlib/1.2.3.3 libidn/1.8 > > Host: localhost:8000 > > Accept: */* > > > * HTTP 1.0, assume close after body > < HTTP/1.0 302 FOUND > < Date: Sun, 24 May 2009 18:09:14 GMT > < Server: WSGIServer/0.1 Python/2.5.2 > < Vary: Cookie > < Content-Type: text/html; charset=utf-8 > < Location: > http://localhost:8000/resources/users/login?next=/resources/users999/forbbidenView/ > < > * Closing connection #0 > You are still not getting to your forbidden view code, as it apparently requires a login. So again, you're getting a redirect, this time to the login url with next set to forward on to the requested url after you have logged in. Karen --~--~-~--~~~---~--~~ 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+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Re: Admin css being weird
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...@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 path, usually > by uninstalling it. > If uninstalling the other one is not an option for you, try to find a way to > clear your python path before loading your 'preferred' Django. > > Ariel. --~--~-~--~~~---~--~~ 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+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Re: use of HttpResponseForbidden(), etc.
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) libcurl/7.18.2 OpenSSL/0.9.8g > zlib/1.2.3.3 libidn/1.8 > Host: localhost:8000 > Accept: */* > * HTTP 1.0, assume close after body < HTTP/1.0 302 FOUND < Date: Sun, 24 May 2009 18:09:14 GMT < Server: WSGIServer/0.1 Python/2.5.2 < Vary: Cookie < Content-Type: text/html; charset=utf-8 < Location: http://localhost:8000/resources/users/login?next=/resources/users999/forbbidenView/ < * Closing connection #0 On May 24, 8:40 am, Karen Tracey wrote: > 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) > > * 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) libcurl/7.18.2 OpenSSL/0.9.8g > > zlib/1.2.3.3 libidn/1.8 > > > Host: localhost:8000 > > > Accept: */* > > > * HTTP 1.0, assume close after body > > < HTTP/1.0 301 MOVED PERMANENTLY > > < Date: Sun, 24 May 2009 15:31:51 GMT > > < Server: WSGIServer/0.1 Python/2.5.2 > > < Content-Type: text/html; charset=utf-8 > > < Location:http://localhost:8000/resources/users999/forbbidenView/ > > < > > * Closing connection #0 > > Well that url didn't get to your forbidden view because it was missing the > trailing slash, so what you got was a redirect to the right url. What > happens if you use the correct url? > > Karen --~--~-~--~~~---~--~~ 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+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Re: Expert
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/ubernostrum/ He goes by the handle ubernostrum and has projects on other sites as well. You can read his blog at b-list.org . He also gave talks at Pycon and DjangoCon last year about writing reusable apps that were very cool to see: http://www.youtube.com/watch?v=A-S0tqpPga4&feature=PlayList&p=D415FAF806EC47A1&index=14 Another good place to check things out at is the Pinax projects. They are trying to get a group of regularly used applications all under one simple project. It is a lot of fun to play with and they are helping to define what makes a Django app useful. http://pinaxproject.com/ Those are just a few examples, just going through django-code and google, you should be able to find a lot more. I hope that helps, Michael --~--~-~--~~~---~--~~ 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+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Re: Revisit Django trunk and Python 2.6
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. --~--~-~--~~~---~--~~ 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+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Re: reset button question
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 reset button be working? --~--~-~--~~~---~--~~ 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+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Re: Admin css being weird
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 path, usually by uninstalling it. If uninstalling the other one is not an option for you, try to find a way to clear your python path before loading your 'preferred' Django. Ariel. --~--~-~--~~~---~--~~ 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+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Re: running django with wsgi over apache
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.2)] on linux2 Type "help", "copyright", "credits" or "license" for more information. >>> import profile.urls Traceback (most recent call last): File "", line 1, in ImportError: No module named urls >>> This looks familiar, right? It is not good to name apps to conflict with standard python modules; someday someone will be confused :). 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. Example: workspace = '/home/gabriel/pywks' project = '/home/gabriel/pywks/vertaal' sys.path = [workspace, project] + sys.path Hope that makes sense. sdc --~--~-~--~~~---~--~~ 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+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Re: Expert
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 tutorial. Write your own app. Look at 3rd party apps for > overall best practices. Start digging into source code. You should be able > to have a pretty good understanding of all that is Django in 3 months. > Especially if you already have a pretty good feeling for python. I don't > know what else to tell you but to just dig in, everyone learns differently, > and this group is more than willing to help you with any specific questions > that you might have in the next 3 months. > > I hope that helps, > > Michael --~--~-~--~~~---~--~~ 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+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Re: please provide a html download of the doc
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/0/django-docs-1.0-html.tgz > > Following your instructions does not work, even on a PC WITH Internet > connection. > I download those four packages from the python-site (sphinx, docutils, > jinja, pygments), > I do a fresh python install (2.6.2), works > I do install the docutils with 'python.exe setup.py install', ok, > works > I do install the jinja with 'python.exe setup.py install', it tries to > down something, bang, i get a http 404 not found-Error. > > Nils > > > > So, exactly as was said, you need an internet connection *once* to install them, that's all. Regardless this is not the place to discuss the installation of other packages. Alex -- "I disapprove of what you say, but I will defend to the death your right to say it." --Voltaire "The people's good is the highest law."--Cicero --~--~-~--~~~---~--~~ 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+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Re: Lost CSS using Django-registration
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 email to django-users@googlegroups.com To unsubscribe from this group, send email to django-users+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Re: please provide a html download of the doc
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 work, even on a PC WITH Internet connection. I download those four packages from the python-site (sphinx, docutils, jinja, pygments), I do a fresh python install (2.6.2), works I do install the docutils with 'python.exe setup.py install', ok, works I do install the jinja with 'python.exe setup.py install', it tries to down something, bang, i get a http 404 not found-Error. Nils --~--~-~--~~~---~--~~ 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+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Re: running django with wsgi over apache
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 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+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Re: multi-table inheritance and binding objects
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 something obvious, but couldn't find it. > > > class Attendee(models.Model): > > > and > > > class Submission(Attendee): > > attendee = models.OneToOneField(Attendee, parent_link=True) > > > extends upon Attendee.with a hand-coded backward relation (I'll be > > happy to drop this if my problem can be solved without it) > > > These work well: > > >>> attendee = models.Attendee.objects.create(user=User.objects.get(pk=1), > > nametag='', conference=conf) > > >>> submit1 = models.Submission.objects.create(user=User.objects.get(pk=1), > > nametag='', conference=conf, title='Title', abstract='Abstract', > > document='no/doc', topic=topic) > > > but how can I bind an already existing Attendee object to a new > > Submission object? Something along the lines of > > > >>> submit2 = models.Submission.objects.create(attendee=attendee, > > title='Title', abstract='Abstract', document='no/doc', topic=topic) > > Traceback (most recent call last): > > File "", line 1, in > > File "/home/nagyv/virtualenv/django-1.0.2/lib/python2.5/site- > > packages/Django-1.0.2_final-py2.5.egg/django/db/models/manager.py", > > line 99, in create > > return self.get_query_set().create(**kwargs) > > File "/home/nagyv/virtualenv/django-1.0.2/lib/python2.5/site- > > packages/Django-1.0.2_final-py2.5.egg/django/db/models/query.py", line > > 319, in create > > obj.save(force_insert=True) > > File "/home/nagyv/workspace/MKKE/conference/models.py", line 212, in > > save > > if not self.topic in self.conference.topic_set.all(): > > File "/home/nagyv/virtualenv/django-1.0.2/lib/python2.5/site- > > packages/Django-1.0.2_final-py2.5.egg/django/db/models/fields/ > > related.py", line 235, in __get__ > > raise self.field.rel.to.DoesNotExist > > DoesNotExist > > > or > > > >>> submit2 = models.Submission(title='Title', abstract='Abstract', > > document='no/doc', topic=topic) > > >>> submit2.attendee = attendee > > >>> submit2.save() > > Traceback (most recent call last): > > File "", line 1, in > > File "/home/nagyv/workspace/MKKE/conference/models.py", line 212, in > > save > > if not self.topic in self.conference.topic_set.all(): > > File "/home/nagyv/virtualenv/django-1.0.2/lib/python2.5/site- > > packages/Django-1.0.2_final-py2.5.egg/django/db/models/fields/ > > related.py", line 235, in __get__ > > raise self.field.rel.to.DoesNotExist > > DoesNotExist > > > thanks, > > Viktor > > Take a look at this ticket:http://code.djangoproject.com/ticket/7623and > possibly the attached patch (I'm not familiar with that patch itself, but > that code looks remarkably similar to some we use where I work). > > Alex > > -- > "I disapprove of what you say, but I will defend to the death your right to > say it." --Voltaire > "The people's good is the highest law."--Cicero --~--~-~--~~~---~--~~ 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+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Re: multi-table inheritance and binding objects
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 > > class Submission(Attendee): >attendee = models.OneToOneField(Attendee, parent_link=True) > > extends upon Attendee.with a hand-coded backward relation (I'll be > happy to drop this if my problem can be solved without it) > > These work well: > >>> attendee = models.Attendee.objects.create(user=User.objects.get(pk=1), > nametag='', conference=conf) > >>> submit1 = models.Submission.objects.create(user=User.objects.get(pk=1), > nametag='', conference=conf, title='Title', abstract='Abstract', > document='no/doc', topic=topic) > > but how can I bind an already existing Attendee object to a new > Submission object? Something along the lines of > > >>> submit2 = models.Submission.objects.create(attendee=attendee, > title='Title', abstract='Abstract', document='no/doc', topic=topic) > Traceback (most recent call last): > File "", line 1, in > File "/home/nagyv/virtualenv/django-1.0.2/lib/python2.5/site- > packages/Django-1.0.2_final-py2.5.egg/django/db/models/manager.py", > line 99, in create >return self.get_query_set().create(**kwargs) > File "/home/nagyv/virtualenv/django-1.0.2/lib/python2.5/site- > packages/Django-1.0.2_final-py2.5.egg/django/db/models/query.py", line > 319, in create >obj.save(force_insert=True) > File "/home/nagyv/workspace/MKKE/conference/models.py", line 212, in > save >if not self.topic in self.conference.topic_set.all(): > File "/home/nagyv/virtualenv/django-1.0.2/lib/python2.5/site- > packages/Django-1.0.2_final-py2.5.egg/django/db/models/fields/ > related.py", line 235, in __get__ >raise self.field.rel.to.DoesNotExist > DoesNotExist > > or > > >>> submit2 = models.Submission(title='Title', abstract='Abstract', > document='no/doc', topic=topic) > >>> submit2.attendee = attendee > >>> submit2.save() > Traceback (most recent call last): > File "", line 1, in > File "/home/nagyv/workspace/MKKE/conference/models.py", line 212, in > save >if not self.topic in self.conference.topic_set.all(): > File "/home/nagyv/virtualenv/django-1.0.2/lib/python2.5/site- > packages/Django-1.0.2_final-py2.5.egg/django/db/models/fields/ > related.py", line 235, in __get__ >raise self.field.rel.to.DoesNotExist > DoesNotExist > > thanks, > Viktor > > > Take a look at this ticket: http://code.djangoproject.com/ticket/7623 and possibly the attached patch (I'm not familiar with that patch itself, but that code looks remarkably similar to some we use where I work). Alex -- "I disapprove of what you say, but I will defend to the death your right to say it." --Voltaire "The people's good is the highest law."--Cicero --~--~-~--~~~---~--~~ 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+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
multi-table inheritance and binding objects
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(Attendee, parent_link=True) extends upon Attendee.with a hand-coded backward relation (I'll be happy to drop this if my problem can be solved without it) These work well: >>> attendee = models.Attendee.objects.create(user=User.objects.get(pk=1), >>> nametag='', conference=conf) >>> submit1 = models.Submission.objects.create(user=User.objects.get(pk=1), >>> nametag='', conference=conf, title='Title', abstract='Abstract', >>> document='no/doc', topic=topic) but how can I bind an already existing Attendee object to a new Submission object? Something along the lines of >>> submit2 = models.Submission.objects.create(attendee=attendee, >>> title='Title', abstract='Abstract', document='no/doc', topic=topic) Traceback (most recent call last): File "", line 1, in File "/home/nagyv/virtualenv/django-1.0.2/lib/python2.5/site- packages/Django-1.0.2_final-py2.5.egg/django/db/models/manager.py", line 99, in create return self.get_query_set().create(**kwargs) File "/home/nagyv/virtualenv/django-1.0.2/lib/python2.5/site- packages/Django-1.0.2_final-py2.5.egg/django/db/models/query.py", line 319, in create obj.save(force_insert=True) File "/home/nagyv/workspace/MKKE/conference/models.py", line 212, in save if not self.topic in self.conference.topic_set.all(): File "/home/nagyv/virtualenv/django-1.0.2/lib/python2.5/site- packages/Django-1.0.2_final-py2.5.egg/django/db/models/fields/ related.py", line 235, in __get__ raise self.field.rel.to.DoesNotExist DoesNotExist or >>> submit2 = models.Submission(title='Title', abstract='Abstract', >>> document='no/doc', topic=topic) >>> submit2.attendee = attendee >>> submit2.save() Traceback (most recent call last): File "", line 1, in File "/home/nagyv/workspace/MKKE/conference/models.py", line 212, in save if not self.topic in self.conference.topic_set.all(): File "/home/nagyv/virtualenv/django-1.0.2/lib/python2.5/site- packages/Django-1.0.2_final-py2.5.egg/django/db/models/fields/ related.py", line 235, in __get__ raise self.field.rel.to.DoesNotExist DoesNotExist thanks, Viktor --~--~-~--~~~---~--~~ 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+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Re: getting error with admin logout
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 it: > http://code.djangoproject.com/ticket/10061 > > How do I apply the patch to django? Thanks. > > > > The patch can be applied using normal unix command line utilities, such as patch (or if you're a git user: git apply), note that you'll probably need to manually specify some paths during the patch process as the patch is a git format diff. Alex -- "I disapprove of what you say, but I will defend to the death your right to say it." --Voltaire "The people's good is the highest law."--Cicero --~--~-~--~~~---~--~~ 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+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Re: Revisit Django trunk and Python 2.6
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. > > > Django trunk (or 1.0.X branch) has no known issues with Python 2.6, I personally use that for development. Alex -- "I disapprove of what you say, but I will defend to the death your right to say it." --Voltaire "The people's good is the highest law."--Cicero --~--~-~--~~~---~--~~ 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+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Re: use of HttpResponseForbidden(), etc.
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) > * 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) libcurl/7.18.2 OpenSSL/0.9.8g > zlib/1.2.3.3 libidn/1.8 > > Host: localhost:8000 > > Accept: */* > > > * HTTP 1.0, assume close after body > < HTTP/1.0 301 MOVED PERMANENTLY > < Date: Sun, 24 May 2009 15:31:51 GMT > < Server: WSGIServer/0.1 Python/2.5.2 > < Content-Type: text/html; charset=utf-8 > < Location: http://localhost:8000/resources/users999/forbbidenView/ > < > * Closing connection #0 > > Well that url didn't get to your forbidden view because it was missing the trailing slash, so what you got was a redirect to the right url. What happens if you use the correct url? Karen --~--~-~--~~~---~--~~ 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+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Re: use of HttpResponseForbidden(), etc.
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 8000 (#0) > GET /resources/users999/forbbidenView HTTP/1.1 > User-Agent: curl/7.18.2 (i486-pc-linux-gnu) libcurl/7.18.2 OpenSSL/0.9.8g > zlib/1.2.3.3 libidn/1.8 > Host: localhost:8000 > Accept: */* > * HTTP 1.0, assume close after body < HTTP/1.0 301 MOVED PERMANENTLY < Date: Sun, 24 May 2009 15:31:51 GMT < Server: WSGIServer/0.1 Python/2.5.2 < Content-Type: text/html; charset=utf-8 < Location: http://localhost:8000/resources/users999/forbbidenView/ < * Closing connection #0 --~--~-~--~~~---~--~~ 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+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Re: running django with wsgi over apache
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 files are > located. > > Admin works so some part of your urlconfig works. But if it contains > an evil include(), that would explain the import error you are getting > whenever you try to call reverse(). That test/ directory seems > suspicious, because there is a python standard module called 'test', > and in the sys.path you posted your directories are appended. > > That's too much guessing but if you had, say, import('test.urls') > somewhere that really would explain the whole thing. Thinking about you said, I had this in my main urlconf urlpatterns = patterns('', url(r'^$', 'app.views.index', name='home'), url(r'^app/', include('app.urls')), url(r'^accounts/', include('registration.urls')), url(r'^projects/', include('projects.urls')), url(r'^releases/', include('releases.urls')), url(r'^languages/', include('languages.urls')), url(r'^contact/', include('contact.urls')), url(r'^profile/', include('profile.urls')), url(r'^components/', include('components.urls')), url(r'^teams/', include('teams.urls')), url(r'^files/', include('files.urls')), url(r'^man/(.*)', admin.site.root), ) I changed to: urlpatterns = patterns('', url(r'^$', 'vertaal.app.views.index', name='home'), url(r'^app/', include('vertaal.app.urls')), url(r'^accounts/', include('vertaal.registration.urls')), url(r'^projects/', include('vertaal.projects.urls')), url(r'^releases/', include('vertaal.releases.urls')), url(r'^languages/', include('vertaal.languages.urls')), url(r'^contact/', include('vertaal.contact.urls')), url(r'^profile/', include('vertaal.profile.urls')), url(r'^components/', include('vertaal.components.urls')), url(r'^teams/', include('vertaal.teams.urls')), url(r'^files/', include('vertaal.files.urls')), url(r'^man/(.*)', admin.site.root), ) And now it works :-? A standard url conf should include my project name (vertaal) or not ? Thanks. -- Kind regards. --~--~-~--~~~---~--~~ 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+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Re: Admin css being weird
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 media from one > version and the Django module loaded had another one. (i.e. Django 1.0 > installed systemwide and Django 1.1 on a virtualenv) > > Regards, > > Ariel. --~--~-~--~~~---~--~~ 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+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Re: Euro DjangoCon Videos
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 Scrum8.com. http://scrum8.com/jpartogi/ http://twitter.com/scrum8 --~--~-~--~~~---~--~~ 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+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Re: Djangonic?
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 "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+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Djangonic?
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-users@googlegroups.com To unsubscribe from this group, send email to django-users+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
reset button question
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, send email to django-users@googlegroups.com To unsubscribe from this group, send email to django-users+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
getting error with admin logout
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 patch to django? Thanks. --~--~-~--~~~---~--~~ 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+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Euro DjangoCon Videos
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 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+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Re: open flash chart 2 & django
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 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+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Re: What, if any, Apache modules are required to implement Django authentication?
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]. This is described with mod_python, but mod_wsgi is possible as well, but I couldn't find the docs in 10 secs. * apache handles authentication, and passes the REMOTE_USER to your django site. Set the docs [3] * apache handles authentication, but still passess all the auth data to django: by default this won't happen with mod_wsgi, but can be allowed. See the docs of mod_wsgi. I hope you will find above the setting you are interested in. :) [1]: http://docs.djangoproject.com/en/dev/topics/auth/#other-authentication-sources [2]: http://docs.djangoproject.com/en/dev/howto/apache-auth/?from=olddocs [3]: http://docs.djangoproject.com/en/dev/howto/auth-remote-user/ have a nice day! On May 23, 11:57 am, Graham Dumpleton wrote: > On May 23, 5:59 am, palewire wrote: > > > > > The default httpd.conf loaded on my CentOS server contains the > > following authentication modules. > > > LoadModule auth_basic_module modules/mod_auth_basic.so > > LoadModule auth_digest_module modules/mod_auth_digest.so > > LoadModule authn_file_module modules/mod_authn_file.so > > LoadModule authn_alias_module modules/mod_authn_alias.so > > LoadModule authn_anon_module modules/mod_authn_anon.so > > LoadModule authn_dbm_module modules/mod_authn_dbm.so > > LoadModule authn_default_module modules/mod_authn_default.so > > LoadModule authz_host_module modules/mod_authz_host.so > > LoadModule authz_user_module modules/mod_authz_user.so > > LoadModule authz_owner_module modules/mod_authz_owner.so > > LoadModule authz_groupfile_module modules/mod_authz_groupfile.so > > LoadModule authz_dbm_module modules/mod_authz_dbm.so > > LoadModule authz_default_module modules/mod_authz_default.so > > > I'm curious which, if any, of them are necessary to use Apache to > > solely run a Django application with authentication. I've consulted a > > few people I trust and received different answers, so I thought I'd > > just fire away a question here. > > > Thanks in advance for your expertise. I find this list a constant > > source of help and encouragement. > > You haven't supplied enough information. > > What type of authentication? Are you wanting to use HTTP Basic of > Digest authentication and have Apache handle it, or do you want to use > form/session based authentication with Django handling it? I suspect > you can also have Django handle HTTP Basic authentication as well. > > So, you are going to have to be clearer about what you are wanting to > do. > > Graham --~--~-~--~~~---~--~~ 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+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Revisit Django trunk and Python 2.6
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 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+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Lost CSS using Django-registration
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 output as expected. * When I load up "registration_form.html" (from the registration app), the CSS stylings disappear. * When I enter the style reference directly into the template (instead of extending the base), the style is loaded properly: Any help would be appreciated, thanks! --~--~-~--~~~---~--~~ 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+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---