Re: javascript variable in url resolver template tag

2009-08-10 Thread Sven Richter
Ok, thank you very much, thats how i am gonna do it. I just didnt think about the fact that django is being done on the server side and the script on the client side. Greetings Sven On Sun, Aug 9, 2009 at 8:20 PM, Daniel Roseman wrote: > > On Aug 9, 4:59 pm, Sven Richter

slug regular expression: which should I use

2009-08-10 Thread J0hnsmith
Which should I use to match a slug made using slugify? (?P[a-zA-Z0-9-]+) or (?P[\w-]+) --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to

Re: django newbie, having problems with my first app. maybe in the urls.py?

2009-08-10 Thread Sujan Shakya
I m not sure if webfaction automatically deploy your django application, but I guess to need to configure server settings. For instructions on deploying http://docs.djangoproject.com/en/dev/howto/deployment/#howto-deployment-index --~--~-~--~~~---~--~~ You

Re: very interesting query... i need some help

2009-08-10 Thread many
one thing i like about django and python in general is that i can read to the source code very easy and come up with some sort of a solution. the reason i want to keep it a queryset is that i want to perform a filter even further. i have come up with a rather simple solution but ineficient. the

Re: javascript variable in url resolver template tag

2009-08-10 Thread Jani Tiainen
Sven Richter kirjoitti: > Ok, i think i understand the problem now. > So i have to hardcode the url in my javascript function? > That was what i wanted to circumvent. No you don't have to. There is two ways, either you just use base URL like {% url url_name %} and send parameters as POST (or

Re: slug regular expression: which should I use

2009-08-10 Thread Eric Abrahamsen
On Aug 10, 2009, at 1:56 PM, J0hnsmith wrote: > > Which should I use to match a slug made using slugify? > > (?P[a-zA-Z0-9-]+) > > or > > (?P[\w-]+) They're not exactly the same. Most of the time \w is alphanumeric (ie equivalent to your first regex) but Django compiles the RegexURLPattern

Re: Recursive request and page layout

2009-08-10 Thread SardarNL
Django solution found - template tags. The way how django discovers the tags makes it easy to publish them. The applications just exports the content as tags and anyone can use it. If request object is needed (for cookie etc) then django.core.context_processors.request template content processor

Django job in Manchester, UK

2009-08-10 Thread Jon Atkinson
Hello, We're a 70% Django, 30% PHP shop in Manchester, in the UK. We're looking to recruit a Django developer in the near future. This might be of interest to some people on this list. Job description and application information: http://bit.ly/qlguI Cheers, --Jon

Re: Code generation

2009-08-10 Thread Michelschr
Hi, You can have a look in the book "Pro Django" from Marty Alchin. For example: p.46 "How Django Processes Model classes"... It seems we are following parallel tracks... Hope it helps... Michel On Aug 9, 3:48 pm, sjtirtha wrote: > Hi Joshua, > > thank you for your

noob question about part 2 of the tutorial

2009-08-10 Thread egrommet
I've just reached http://docs.djangoproject.com/en/1.0/intro/tutorial02/#adding-related-objects in the tutorial and am trying then to follow on. I've hit the par "Remove the register() call for the Choice model. Then, edit the Poll registration code to read: class

Re: django newbie, having problems with my first app. maybe in the urls.py?

2009-08-10 Thread gumbah
I read "from mysite.views import hello " in your code... are you sure your webapp is in the "mysite" folder? best regards On Aug 10, 1:45 am, "ezulo...@gmail.com" wrote: > So i am very new to django and have a little python experience. im > using webfraction to host my

Re: django newbie, having problems with my first app. maybe in the urls.py?

2009-08-10 Thread gumbah
Whoops... i see now that it never even finds your urs.py so it must be something wrong with the configuration on webfaction... you have to look into your /webapps/PROJECT_NAME/apache/conf/ httpd.conf file to see if everything is setup correctly. On Aug 10, 12:01 pm, gumbah

ModelForm validation

2009-08-10 Thread nostradamnit
I have a form that inherits from ModelForm, and in my view, form.is_valid returns true, then save() bombs out with validation errors?!? Does anyone know of a good tutorial/doc on this? Thanks, Sam --~--~-~--~~~---~--~~ You received this message because you are

Re: noob question about part 2 of the tutorial

2009-08-10 Thread nostradamnit
It means you remove the line that says admin.site.register(Choice), as the choices will be integrated in the Poll admin page now. On Aug 10, 11:28 am, egrommet wrote: > I've just > reachedhttp://docs.djangoproject.com/en/1.0/intro/tutorial02/#adding-related... > in the

Re: How do I minimize memory usage with WSGI and Apache?

2009-08-10 Thread Dj Gilcrease
On Sun, Aug 9, 2009 at 4:17 PM, Graham Dumpleton wrote: > On Aug 10, 6:07 am, Jumpfroggy wrote: >> I'm hosting a bunch of django apps on a shared host with 80MB of >> application memory (Webfaction in this case).  I've got a bunch of >> apps

Running django tests

2009-08-10 Thread Filip Gruszczyński
Hi! I would like to run django source code tests, but as soon as I do it (after specifying the settings file), I get all kinds of exceptions. Any idea, what am I doing wrong? I post the exceptions below. grusz...@gruszczy-laptop:~/django/tests# PYTHONPATH=..

django-cms-2.0 problem

2009-08-10 Thread Rob B (uk)
Trying to get a default install of : http://github.com/digi604/django-cms-2.0/ up and running on my dev but I'm getting this error when trying to log into admin http://dpaste.com/77696/ Any ideas? --~--~-~--~~~---~--~~ You received this message because you are

dynamic inserting items to template

2009-08-10 Thread elminio
Hello, Is it possible to insert to the template for example 10 checkboxes I know syntax of iterating through objects in list and do some task for each item but Im interested in normal for loop like for i in xrang(10): insert checkbox thanks for reply

Cross post from Djangoindia list: [Pycon] IRC Meeting to discuss how to represent Django

2009-08-10 Thread shabda
[Repost from djangoindia(http://groups.google.com/group/djangoindia) list. Please reply there(http://groups.google.com/group/djangoindia/ browse_thread/thread/72c220038d52f12c) if you are interested.] Hi, With Pycon's talk submission deadline just a week away and only 1 talk on our favourite web

Re: How do I minimize memory usage with WSGI and Apache?

2009-08-10 Thread Graham Dumpleton
On Aug 10, 8:44 pm, Dj Gilcrease wrote: > On Sun, Aug 9, 2009 at 4:17 PM, Graham > > Dumpleton wrote: > > On Aug 10, 6:07 am, Jumpfroggy wrote: > >> I'm hosting a bunch of django apps on a shared host with 80MB of >

Backend Neutral DictCursor

2009-08-10 Thread Chris
You can get a backend neutral database cursor with django.db.connection.cursor(). However, any results executed are returned as nameless lists. Is there a way to get results returned as dictionaries, via DictCursor? MySQL uses MySQLdb.cursors.DictCursor and PostgreSQL uses

Styling a formset

2009-08-10 Thread olivergeorge
Hello I'm trying to add some css styling to fields in a formset but there aren't an good classes to work with. Each field has a id which could be used for styling but it has it's index embedded in it. For example: id="id_educationequipment_set-0-id" That's not very helpful for CSS... I'd need

Re: ModelForm validation

2009-08-10 Thread Karen Tracey
On Mon, Aug 10, 2009 at 6:09 AM, nostradamnit wrote: > > I have a form that inherits from ModelForm, and in my view, > form.is_valid returns true, then save() bombs out with validation > errors?!? > is_valid is a method. If you are checking it "if form.is_valid:" that is

Re: Running django tests

2009-08-10 Thread Karen Tracey
2009/8/10 Filip Gruszczyński > > Hi! > > I would like to run django source code tests, but as soon as I do it > (after specifying the settings file), I get all kinds of exceptions. > Any idea, what am I doing wrong? I post the exceptions below. > >

Admin Panel and ManyToMany

2009-08-10 Thread Joseph Le Brech
Hi All, I'm trying to add a manytomany field so that it shows up on the admin panel for the model, but it does not look like it's working. The relationship is done via a through model. I want a list of the many items belonging to my model. Thanks, Joseph

Using django.root in mod_python

2009-08-10 Thread lfrodrigues
Hello, All my previous projects I've deployed them on the root of a web address. Now I have to deploy two in the same address eg: http://myserver.com/proj1 http://myserver.com/proj2 I'm using django.root to set the correct root (with works fine). I just have two questions: 1 - all the media are

Custom model field and Django-admin -- error

2009-08-10 Thread BenW
Hello, I'm working with a legacy database that stores datetimes as unsigned ints. Rather than do the conversion with properties on the model I've written a custom Field 'UnixDateTimeField': class UnixDateTimeField(models.DateTimeField): __metaclass__ = models.SubfieldBase def

Re: Running django tests

2009-08-10 Thread Filip Gruszczyński
Indeed it helped. Thanks a lot, Karen. 2009/8/10 Karen Tracey : > 2009/8/10 Filip Gruszczyński >> >> Hi! >> >> I would like to run django source code tests, but as soon as I do it >> (after specifying the settings file), I get all kinds of exceptions. >>

Re: slug regular expression: which should I use

2009-08-10 Thread J0hnsmith
Thanks Eric, that does answer my question. On Aug 10, 3:03 pm, Eric Abrahamsen wrote: > On Aug 10, 2009, at 1:56 PM, J0hnsmith wrote: > > > > > Which should I use to match a slug made using slugify? > > > (?P[a-zA-Z0-9-]+) > > > or > > > (?P[\w-]+) > > They're not exactly the

Re: How do I minimize memory usage with WSGI and Apache?

2009-08-10 Thread Dj Gilcrease
On Mon, Aug 10, 2009 at 6:43 AM, Graham Dumpleton wrote: > These values for min and max threads are a bit dubious because you > have a single process and that will have fixed 25 threads. Usually > these are defined in multiples of ThreadsPerChild and not less like >

Django comments honeypot hide

2009-08-10 Thread Alessandro Ronchi
I need to hide the django-comments honeypot in my comment form, but It's visible to the user. Is there a way to do that in an easy way? -- Alessandro Ronchi SOASI Sviluppo Software e Sistemi Open Source http://www.soasi.com --~--~-~--~~~---~--~~ You received

bidirectional m2m in admin page

2009-08-10 Thread gentlestone
Suppose I have a model: - class Person(models.Model): name = models.CharField(max_length=max) class Group(models.Model): name = models.CharField(max_length=max) persons = models.ManyToManyField(Person)

Re: Custom model field and Django-admin -- error

2009-08-10 Thread Alex Gaynor
On Mon, Aug 10, 2009 at 8:45 AM, BenW wrote: > > Hello, > > I'm working with a legacy database that stores datetimes as unsigned > ints.  Rather than do the conversion with properties on the model I've > written a custom Field 'UnixDateTimeField': > > class

Re: Custom model field and Django-admin -- error

2009-08-10 Thread Jean Stebens
Alex Gaynor wrote: > On Mon, Aug 10, 2009 at 8:45 AM, BenW wrote: > >> Hello, >> >> I'm working with a legacy database that stores datetimes as unsigned >> ints. Rather than do the conversion with properties on the model I've >> written a custom Field 'UnixDateTimeField':

Re: Custom model field and Django-admin -- error

2009-08-10 Thread BenW
Excellent that it was reported, but bad that it's not considered a 'bug' -- Any suggestions on how to use date_hierarchy (and probably others) with my field? On Aug 10, 8:04 am, Alex Gaynor wrote: > On Mon, Aug 10, 2009 at 8:45 AM, BenW wrote: > > >

IE problems w. admin save

2009-08-10 Thread Jesper Rasmussen
Hi there, I'm developing a simple Django system (Sqlite) -- using Firefox everything works. When using IE (7) the save button on the admin pages workes strangely: If there is some error in the entered data it just displays a blank page, if no errors is made it displays an "Internet Explorer

looping over forms in a formset

2009-08-10 Thread bnl
hi folks I have a formset, which I want to display using a customised template for the forms. This works: {{formset.mangement_form}} {% for form in formset.forms %} {{form}} {% endfor %} The following displays ok, let's me edit one form, but then I can't update it or add another, failling

Django: Add SET DATESTYLE

2009-08-10 Thread Bdfy
How to add a phrase "SET DATESTYLE =" bla-bla-bla "" for everyone SQL query ? --~--~-~--~~~---~--~~ 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

Re: looping over forms in a formset

2009-08-10 Thread bnl
Why I didn't find this before? It seems Paul had the same problem, and one has to loop over the hidden fields in each form ... {% for hid in form.hidden_fields %} {{hid}}{% endfor %} On Aug 10, 4:59 pm, bnl wrote: > hi folks > > I have a formset, which I want

Re: Django: Add SET DATESTYLE

2009-08-10 Thread Karen Tracey
On Mon, Aug 10, 2009 at 12:00 PM, Bdfy wrote: > > How to add a phrase "SET DATESTYLE =" bla-bla-bla "" for everyone SQL > query ? > Why do you think you want to do that? The Django ORM takes the date(time) values coming from the database and converts them do Python

How to manually set FileField path

2009-08-10 Thread Jo
Hi, I need to set the content of a FileField manually, ie not using the admin screens. The instance of the model that contains the FileField already exists, but has the FileField is currently none. I know the local path for the file, but just can't work out how to update the FileField so I can

How do I sort a ManyToManyField in Django admin?

2009-08-10 Thread Thierry
I currently have the following models: class Image(models.Model): alt_name = models.CharField(max_length=200) def __unicode__(self): return self.alt_name class Album(models.Model): images = models.ManyToManyField(Image, blank=True) class AlbumAdmin(admin.ModelAdmin):

Re: Dynamic Auth Backend and subdomains

2009-08-10 Thread coulix
no clues or unclear ? :) On Aug 9, 1:44 am, coulix wrote: > Hello Pony Wizards, > > I am facing a use case where my authentication process is variable > depending on the request.subdomain catched by a custom > GetSubdomainMiddleware. > > AAA.example.com/login >

Re: IE problems w. admin save

2009-08-10 Thread Jeff Green
I am having similar problems with IE using formsets and the admin functionality. I tend to believe it is an issue with IE but I haven't been able to determine what the issue is. On Mon, Aug 10, 2009 at 10:42 AM, Jesper Rasmussen wrote: > > Hi there, > > I'm developing a

Re: Custom manager and delete()

2009-08-10 Thread Michael Goffioul
Just as a follow-up. I ended up switching to Elixir to handle my multiple legacy databases, while keeping django to handle the main system. The syntax is very similar, and it provides some additional flexibility that allows me to deal with those legacy DB's (like dealing with non-indexed tables).

RE: Admin Panel and ManyToMany

2009-08-10 Thread Joseph Le Brech
Sorry guys, I've found what to do and it's in the tutorial. InlineAdmin, tut. From: jlebr...@hotmail.com To: django-users@googlegroups.com Subject: Admin Panel and ManyToMany Date: Mon, 10 Aug 2009 14:05:31 +0100 Hi All, I'm trying to add a manytomany field so that it shows up on the

Re: Custom manager and delete()

2009-08-10 Thread Adi Andreias
I manage to do row delete operations. Not very nice, since there's no delete-related, no signalst etc. I don't think delete can be fixed for multiple databases without modifying Django source or without duplicating code. Since delete_objects function uses the global connection variable. Would be

Re: How do I minimize memory usage with WSGI and Apache?

2009-08-10 Thread Jumpfroggy
Wow, lots of good feedback here. Thanks! On Aug 9, 6:17 pm, Graham Dumpleton wrote: > Replace use of mod_python with mod_wsgi. I'm using mod_wsgi for everything already, forgot to say. When I researched, it seemed like the newer/better way to do django. > Ensure

Re: need help with model design and table relationship

2009-08-10 Thread Unnamed_Hero
Here is the solution. There is no need in Many-to-many here. In people table I've set corp's unique number as a ForeignKey to Corp's table. In a template: {% for i in result %} {% for persons in i.dolgnost_set.all %} {{ person.field1 }} where Dolgnost - a table with people.

Default value for fields

2009-08-10 Thread AG
I have a field: revision = models.IntegerField(default=0) on a model. I assumed that if I set a default value for a field, I am free to create an object that does not set 'revision', and save it. However, this produces an IntegrityError: IntegrityError: XXX.revision may not be NULL When I check

Re: user online

2009-08-10 Thread Rob B (uk)
Thanks Daniel. Im still quite new to python / django and not sure how to pass OnlineUsers.get_online_user_ids() into the context. My view to list all profiles looks like this: def profile_list(request): return render_to_response('profile_list.html', {

Re: Default value for fields

2009-08-10 Thread Karen Tracey
On Mon, Aug 10, 2009 at 1:59 PM, AG wrote: > > I have a field: > revision = models.IntegerField(default=0) > on a model. > > I assumed that if I set a default value for a field, I am free to > create an object that does not set 'revision', and save it. > However, this

Re: Default value for fields

2009-08-10 Thread ankit rai
check ur db table ,is null=true present.And in ur model write revision = models.IntegerField(default=0,balnk=true,null=true) and if u donont want to change the value from 0 at all then there is no need to diplay it in fields On Mon, Aug 10, 2009 at 11:29 PM, AG wrote: > >

Re: Default value for fields

2009-08-10 Thread Karen Tracey
On Mon, Aug 10, 2009 at 2:13 PM, ankit rai wrote: > check ur db table ,is null=true present.And in ur model write > revision = models.IntegerField(default=0,balnk=true,null=true) > and if u donont want to change the value from 0 at all then there is no > need to diplay it in

Re: How do I minimize memory usage with WSGI and Apache?

2009-08-10 Thread dartdog
Big help!! Had just started getting using too much memory notices from Webfaction yesterday evening... The other item is using the crontab -e command from ssh to comment out apps you don't need to have running For some reason could not find that when I was looking for it and one of my sites

Passing optional URL params to reverse() function

2009-08-10 Thread nabucosound
Hi all: I have a URLconf url entry like this: url( regex=r'^(?P\w+)/(?P[-\w]+)/$', view='show_post', name='show_post', kwargs={'msg': None}, ), and I want to call it with HttpResponseRedirect and reverse(): filters = {'category': post.category.name,

Passing optional URL params to reverse() function

2009-08-10 Thread nabucosound
Hi all: I have a URLconf url entry like this: url( regex=r'^(?P\w+)/(?P[-\w]+)/$', view='show_post', name='show_post', kwargs={'msg': None}, ), and I want to call it with HttpResponseRedirect and reverse(): filters = {'category': post.category.name, 'slug':

Re: dynamic inserting items to template

2009-08-10 Thread Antoni Aloy
2009/8/10 elminio : > > Hello, > Is it possible to insert to the template for example 10 checkboxes > > I know syntax of iterating through objects in list and do some task > for each item but Im interested in normal for loop > like > > for i in xrang(10): >    insert

Re: overriding save()

2009-08-10 Thread neridaj
when I do this it just creates a unix executable file of the same name selected from the drop down menu of users, i.e., if a user named testuser24 is selected from the user menu and there is a folder named testuser24 a unix executable is created named testuser24_. Does this have something to do

help with excel exports

2009-08-10 Thread Bobby Roberts
Hi all - I'm pushing content to a template which i have built to properly organize the data for an excel spreadsheet. I'm generating the response in my view as such: response = render_to_response("spreadsheet.html", { 'tms': tms, }) response['Content-Type'] =

Re: user online

2009-08-10 Thread Daniel Roseman
On Aug 10, 7:10 pm, "Rob B (uk)" wrote: > Thanks Daniel. > Im still quite new to python / django and not sure how to pass > OnlineUsers.get_online_user_ids() into the context. My view to list > all profiles looks like this: > def profile_list(request): > >        

Contact form

2009-08-10 Thread When ideas fail
Hi, i've created a contact fom based on the one in the docs but i don't know what to put as the action in the form element as part of template. I've got this template: {{ form.as_p }} but presuambly the data is being handled by the view. I'd appreciate any help, i tried it without an action

Re: Contact form

2009-08-10 Thread Daniel Roseman
On Aug 10, 8:23 pm, When ideas fail wrote: > Hi, i've created a contact fom based on the one in the docs but i > don't know what to put as the action in the form element as part of > template. I've got this template: > > > {{ form.as_p }} > > > > but presuambly the

Any solution as DjangoKit but for windows ?!

2009-08-10 Thread Hamza
Hello , i have been searching for a week now about a solution making it easy to deploy django projects as desktop application , somehow i found some detailed articles and tutorials ( 3 ) for making this happen for windows , but with DjangoKit its pretty much easier and simpler , the question is

Multiple application instances?

2009-08-10 Thread Andrin Riiet
In the django documentation -> URL dispatcher -> Defining URL namespaces it reads "When you need to deploy multiple instances of a single application, it can be helpful to be able to differentiate between instances" I am unable to find any kind of documentation on how to "deploy multiple

Re: Contact form

2009-08-10 Thread When ideas fail
Ok thanks, i'll have a look at the setup then. On 10 Aug, 20:29, Daniel Roseman wrote: > On Aug 10, 8:23 pm, When ideas fail wrote: > > > > > Hi, i've created a contact fom based on the one in the docs but i > > don't know what to put as the

Re: Django comments honeypot hide

2009-08-10 Thread Luke Seelenbinder
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 xhtml: html: Luke Seelenbinder luke.seelenbin...@gmail.com http://www.google.com/profiles/luke.seelenbinder -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.9 (GNU/Linux) iEYEARECAAYFAkqAgj8ACgkQXQrGVCncjPz8FACffs+kJ757sMZIB2MEiuLX7V9P

Question about request.user

2009-08-10 Thread David
hello, Here is what I met. I logined into my Django application online with a username "peter". Then I logined with another username "john". All seemed fine. Now I printed user name in "john" account, and it gave "peter". I used following code. if request.user.is_authenticated(): print

Re: Question about request.user

2009-08-10 Thread Carlos A. Carnero Delgado
Hi, On Mon, Aug 10, 2009 at 4:46 PM, David wrote: > Why request.user.username did not bind to "john" in this scenario? > Anybody knows what caused such a problem? And any ideas how to fix > it? Are you using the same web browser? Maybe two tabs? HTH, Carlos.

Testing code that uses geopy

2009-08-10 Thread Sean Brant
I have written some unit tests that test various parts of code that utilize geopy for determining geo locations. Should I be running my tests using the geocoder class, or should I create a mock class that does not actually ping any services? If creating a mock class is recommended should I

Re: Question about request.user

2009-08-10 Thread David
Hi Carlos, Thanks for your reply. I opened two broswers. I first logined as "peter" and I left IE there; then I double-clicked IE icon on my desktop to open a new one. On this new one I logined as "john". There is only one user table as I use "django.contrib.auth.models.User". any more ideas?

Re: user online

2009-08-10 Thread Rob B (uk)
Im reading through loads of python / django tutorials atm, hopefully some of it will stick! I added what you suggested and now I'm getting the error "type object 'OnlineUsers' has no attribute 'get_online_user_ids'" view - http://dpaste.com/77965/ middleware (name OnlineUsers) -

Is it possible to skip this field?

2009-08-10 Thread David
Hello, When I use the following code, {{ form.as_table }} . It prints all form fields with corresponding values on a user's monitor. Now that in that form there is a field "username", for some reasons I can not show this information to that user even

Re: Is it possible to skip this field?

2009-08-10 Thread Daniel Roseman
On Aug 10, 10:58 pm, David wrote: > Hello, > > When I use the following code, > >   >         >             {{ form.as_table }} >         > > . > > It prints all form fields with corresponding values on a user's > monitor. Now that in that form there is a field

FK problem: can it point to an object which hasn't been saved yet?

2009-08-10 Thread George Laskowsky
Hi, I have the following problem: I have a hierarchy of models, each one with a FK pointing to its "father" class. Something like: class Model1(models): data ... class Model2(models): data ... father = models.ForeignKey(Model1) class Model3(models): data ... father =

syncdb with ForeignKey to_field outputs statements in wrong order

2009-08-10 Thread physicsnick
Hello, I'm trying to use ForeignKey on a specific indexed column using the to_field attribute. Unfortunately syncdb seems to be outputting the ADD CONSTRAINT statement before the CREATE INDEX on the to_field, so mysql refuses to add the constraint and syncdb quits with an exception. Here's a

SPAM/FRAUD WARNING: Do NOT open the email with subject "Django enquiry"

2009-08-10 Thread David Ross @ Wolfeon
I received an email a few minutes ago with the subject "Django enquiry." My email address in relation to django was phished from djangopeople or the mailing list. There is a 1x1 image contained in the email which is possibly used for verifying addresses. Don't take the spam seriously, the

Re: Is it possible to skip this field?

2009-08-10 Thread David
Great. Thanks Daniel! On Aug 10, 3:04 pm, Daniel Roseman wrote: > On Aug 10, 10:58 pm, David wrote: > > > > > > > Hello, > > > When I use the following code, > > >   > >         > >             {{ form.as_table }} > >         > > > . > > > It

Re: user online

2009-08-10 Thread Daniel Roseman
On Aug 10, 10:45 pm, "Rob B (uk)" wrote: > Im reading through loads of python / django tutorials atm, hopefully > some of it will stick! > > I added what you suggested and now I'm getting the error "type object > 'OnlineUsers' has no attribute 'get_online_user_ids'" >

Re: user online

2009-08-10 Thread Rob B (uk)
Brill thanks. Its actaully working! Getting a the IDs with the template: {% for user_set in online_users %} {{ user_set }} {% empty %} To list the usernames instead of the ID will I need to update the view or is there a clever trick with the template? On Aug 10, 11:02 pm, Daniel Roseman

Re: SPAM/FRAUD WARNING: Do NOT open the email with subject "Django enquiry"

2009-08-10 Thread Tim Chase
David Ross @ Wolfeon wrote: > I received an email a few minutes ago with the subject "Django > enquiry." My email address in relation to django was phished from > djangopeople or the mailing list. Confirmed -- I received the same email, clearly from djangopeople (I registered there as

Question about URLs

2009-08-10 Thread When ideas fail
If i have a URL such as: (r'^(?P\w+)/blog/', include('foo.urls.blog')), what are the whats the purpose of the w and the +? i'm having some problems with 2 of my urls and i think it may have something to do with this. Thanks --~--~-~--~~~---~--~~ You received

paginator for 0.96?

2009-08-10 Thread Bobby Roberts
is there any other examples of how to use the paginator in 0.96 other than this: http://www.djangoproject.com/documentation/0.96/models/pagination/#sample-usage I'm looking more specifically for template side use so I can see how to work it. Thanks in advance,

Two user authentication systems

2009-08-10 Thread nerdydork
I have a budgeting application I created at inzolo.com. I want to create an affiliate program to offer commissions to those who refer paying users to the site. I will basically have a different login and just for affiliates. I'm wondering how to best handle this situation. Can I copy the

Trouble installing Django-CMS 2

2009-08-10 Thread odonnell
Hello everyone, I'm having quite a lot of pain installing django-cms 2.0, which is available at http://github.com/digi604/django-cms-2.0/tree/master. When I visit /admin/, I get a "TemplateSyntaxError at /admin/" with the subtitle "Caught an exception while rendering: u'user' ." I suck at

Re: django-cms-2.0 problem

2009-08-10 Thread Karl Bowden
On Mon, Aug 10, 2009 at 9:22 PM, Rob B (uk) wrote: > > Trying to get a default install of : > http://github.com/digi604/django-cms-2.0/ > up and running on my dev but I'm getting this error when trying to log > into admin > http://dpaste.com/77696/ > > Any ideas? Good

Re: django-cms-2.0 problem

2009-08-10 Thread odonnell
Holy shit! I just posted the EXACT SAME PROBLEM two seconds ago. On Aug 10, 3:43 pm, Karl Bowden wrote: > On Mon, Aug 10, 2009 at 9:22 PM, Rob B (uk) wrote: > > > Trying to get a default install of : > >http://github.com/digi604/django-cms-2.0/ >

Re: django-cms-2.0 problem

2009-08-10 Thread odonnell
I just had the same problem and I've isolated the issue, sort of. I commented out all the stuff to do with CMS in settings.py and urls.py, except the line "django.core.context_processors.request", in TEMPLATE_CONTEXT_PROCESSORS. The issue still persisted. When I commented that out, too, I was

Re: django-cms-2.0 problem

2009-08-10 Thread odonnell
I'll try starting with the example project this time, maybe something in there is different than starting a project with django-admin.py startproject. On Aug 10, 3:43 pm, Karl Bowden wrote: > On Mon, Aug 10, 2009 at 9:22 PM, Rob B (uk) wrote: > >

Re: Django comments honeypot hide

2009-08-10 Thread Adam Playford
Any reason not to just hide it with CSS? Something like: #honeypotField { display: none; } Assuming that the field's ID is set to "honeypotField"? (Alternatively, if you're not using an external stylesheet, you could use: style = "display: none;" as a property of the item.) Adam On Aug

Re: How do I minimize memory usage with WSGI and Apache?

2009-08-10 Thread Jumpfroggy
On Aug 10, 2:24 pm, dartdog wrote: > Big help!! Had just started getting using too much memory notices from > Webfaction yesterday evening... Yeah, I didn't even pay attention till I hit about 120-140MB on my 80MB plan and got everything turned off. Otherwise I would have

Re: django-cms-2.0 problem

2009-08-10 Thread Matthias Kestenholz
On Tue, Aug 11, 2009 at 1:01 AM, odonnell wrote: > > I'll try starting with the example project this time, maybe something > in there is different than starting a project with django-admin.py > startproject. > The standard django project skeleton does not have

Re: django-cms-2.0 problem

2009-08-10 Thread odonnell
Thanks, everything works when you start with the sample project. On Aug 10, 3:43 pm, Karl Bowden wrote: > On Mon, Aug 10, 2009 at 9:22 PM, Rob B (uk) wrote: > > > Trying to get a default install of : > >http://github.com/digi604/django-cms-2.0/ >

Re: django-cms-2.0 problem

2009-08-10 Thread odonnell
Okay, that's probably what got both of us. Thanks! On Aug 10, 4:09 pm, Matthias Kestenholz wrote: > On Tue, Aug 11, 2009 at 1:01 AM, odonnell wrote: > > > I'll try starting with the example project this time, maybe something > > in there is different

Generic view 'archive_year' produces blank HTML page

2009-08-10 Thread Matthew
I am using Django's generic views to create a blog site. The templates I created, entry_archive_day, entry_archive_month, entry_archive, and entry_detail all work perfectly, but entry_archive_year does not. Instead, it is simply a blank page. It looks like it sees no objects in 'object_list'.

Re: Question about URLs

2009-08-10 Thread Tim Chase
> If i have a URL such as: > > (r'^(?P\w+)/blog/', include('foo.urls.blog')), > > what are the whats the purpose of the w and the +? i'm having some > problems with 2 of my urls and i think it may have something to do > with this. You'll want to read up on regular expressions. There are a

Re: Question about request.user

2009-08-10 Thread David
I tested this again with IE and Firefox. On IE I logined as "peter" and then I logined as "john" on Firefox. Now I checked user in "peter" account with "request.user.username", and I got "john". Can anybody do this test on your machine? Thanks so much. On Aug 10, 2:48 pm, David

Re: How do I minimize memory usage with WSGI and Apache?

2009-08-10 Thread Graham Dumpleton
On Aug 11, 12:25 am, Dj Gilcrease wrote: > On Mon, Aug 10, 2009 at 6:43 AM, Graham > > Dumpleton wrote: > > These values for min and max threads are a bit dubious because you > > have a single process and that will have fixed 25 threads.

Re: How do I minimize memory usage with WSGI and Apache?

2009-08-10 Thread Graham Dumpleton
On Aug 11, 3:11 am, Jumpfroggy wrote: > Wow, lots of good feedback here.  Thanks! > > On Aug 9, 6:17 pm, Graham Dumpleton > wrote: > > > Replace use of mod_python with mod_wsgi. > > I'm using mod_wsgi for everything already, forgot to say.  

Re: overriding save()

2009-08-10 Thread Karen Tracey
On Mon, Aug 10, 2009 at 3:07 PM, neridaj wrote: > > when I do this it just creates a unix executable file of the same name > selected from the drop down menu of users, i.e., if a user named > testuser24 is selected from the user menu and there is a folder named > testuser24 a

  1   2   >