Re: How do you use multiple forms on one page?

2006-11-27 Thread enigmadude
Thank you for the info. I checked out the dev version and it looks like the attrs parameter is the sort of thing I was looking for, concerning the CSS issue. As for the multiple forms issue, I guess I'll have to come up with some classes or helper functions to keep that kind of stuff separated.

Re: Strange Template/Model Error

2006-11-27 Thread Steve Wedig
Fixed this problem. That's the second time I've searched for 1 hour+, wrote an email, and then quickly figured out a solution. I wonder if writing the email helps... Anyway, the problem seemed to be that I was overriding the __getitem__ method to make my model instances work more like a

Strange Template/Model Error

2006-11-27 Thread Steve Wedig
Hello, I am using multiple inheritance on a model. I'm just subclassing Model and subclassing a class that acts like a mixin. The mixin only adds or overrides methods. Anyway, this works fine with the python api, but is causing problems inside a template. When inside a template, I get an error

Re: Moving from development server to apache

2006-11-27 Thread Kenneth Gonsalves
On 28-Nov-06, at 12:00 PM, David Abrahams wrote: > Finally, I had to explicitly specify a PostgreSQL user in my > settings.py file, because my apache runs as a different user (www) > than the one that created the database, and although I used > psql to say you have an app called 'myapp'.

Moving from development server to apache

2006-11-27 Thread David Abrahams
I've been very happily developing my Django site with the development server, and decided it was time to start it under Apache. I ran into several problems that really slowed my development down. I'm posting here because: a. I'd love some help with these if anyone can offer it; many of my

Re: Django AMF

2006-11-27 Thread Tomohiro Otsuka
Condredge, > Oooh, sweetness! Now I can switch over my RIAs from CF into > Python/Django - very nice Tmohiro! > > Will this work with Flash MX 2004? Django AMF supports AMF version 0 which is used by Flash Remoting components. So with the components correspondent to your Flash IDE version, it

Re: More questions on models

2006-11-27 Thread Brian Beck
Jim Fritchman wrote: > The key being the list of order items in the Order class? Hi Jim, I think the closest equivalent would be: from django.db.models import * class Order(Model): class Meta: db_table = 'orders' class Product(Model): pass class OrderItem(Model):

Re: missing auth_user_group and auth_group_permissions tables

2006-11-27 Thread yun
Thanks for the advice. I've checked that the settings.py file was saved before syncing the database. The correct setting file is getting loaded. And finally there is no problem with the PYTHONPATH. The project is the first one shown when using '>>>sys.path'. The tables that were created were:

Re: More questions on models

2006-11-27 Thread Russell Keith-Magee
On 11/28/06, Jim Fritchman <[EMAIL PROTECTED]> wrote: > > The following is SQLObject code and I would like to know how I would do > the same in Django? > > class Order(SQLObject): > items = MultipleJoin('OrderItem', joinColumn='order_id') > > class sqlmeta: > table = 'orders' > >

Character length issue using core.mail.send_mail

2006-11-27 Thread luxagraf
Hello all I've got an issue with django.core.mail that's driving me crazy... I'm using a custom manipulator to handle the data submitted through a web contact form... everything works great except that when I import and try to use send_mail() from django.core.mail I get strange results

using freecomments wits cheetah templates

2006-11-27 Thread sandro.dentella
Hi, has anybody a working example on how to use comments using cheetah templates? is it any possible? I guess I should wrap CommentListNode in a function that returns directly the result rather than adding it to the context, is that correct? TIA sandro *:-)

seeking any advice re: directions

2006-11-27 Thread Chris Ryland
I'm jumping into Django right now, converting from Zope, and wonder if anyone has any helpful thoughts or even hints about exactly what direction to take, given our situation. And perhaps this thread might be useful to someone else, since it's a fairly common scenario. I'm building a typical

More questions on models

2006-11-27 Thread Jim Fritchman
The following is SQLObject code and I would like to know how I would do the same in Django? class Order(SQLObject): items = MultipleJoin('OrderItem', joinColumn='order_id') class sqlmeta: table = 'orders' class OrderItem(SQLObject): quantity = IntCol(notNone=True) price

Re: Debugging emails

2006-11-27 Thread Don Arbow
On Nov 27, 2006, at 4:59 PM, [EMAIL PROTECTED] wrote: > I think that may be it, but something's still not right. > > I now have: > DEBUG = False > TEMPLATE_DEBUG = False > > ADMINS = ( > ('Tim Baxter', '[EMAIL PROTECTED]'), > ) > > MANAGERS = ADMINS > EMAIL_HOST='mail2.webfaction.com' #

Re: Session problems

2006-11-27 Thread Graham Dumpleton
Adrian Holovaty wrote: > On 11/7/06, Jakub Labath <[EMAIL PROTECTED]> wrote: > > If you take a look at the attached log you will see the same child > > process having the same request._req object for two different IP > > addresses. Now this should not normally happen should it. The memory > >

Re: How to do not in Joins

2006-11-27 Thread Russell Keith-Magee
On 11/27/06, halmcelroy <[EMAIL PROTECTED]> wrote: > > In SQL this would translate as: > SELECT * FROM A WHERE ID NOT IN (SELECT ID FROM B) ... > for.eg. A.objects.filter().exclude(this__not_in=[.. some list of > objects that I want to exclude]) > > Can anyone throw some light on how to use the

Re: Debugging emails

2006-11-27 Thread [EMAIL PROTECTED]
I think that may be it, but something's still not right. I now have: DEBUG = False TEMPLATE_DEBUG = False ADMINS = ( ('Tim Baxter', '[EMAIL PROTECTED]'), ) MANAGERS = ADMINS EMAIL_HOST='mail2.webfaction.com' # webfaction says this is the smtp server EMAIL_HOST_USER='XX' # my email

Re: How to get request.user in templatetag?

2006-11-27 Thread Ivan Sagalaev
Rob Hudson wrote: > The place I need it is the: > class CommentFormNode(template.Node): You probably need it in this node's 'render' method. There you have a context passed to it and this context is exactly the thing that holds all the variables including 'user'. So this is it:

Re: Debugging emails

2006-11-27 Thread Don Arbow
On Nov 27, 2006, at 3:00 PM, [EMAIL PROTECTED] wrote: > > I understand Django should send an email when there's an error and > debug=False. > > It doesn't. Not for me anyway. Do you have an email server defined? If not, Django tries to use the localhost to send. Do something like this in your

How to get request.user in templatetag?

2006-11-27 Thread Rob Hudson
I'm making a templatetag and would like to display some user specific information along with the output. I'm doing a check to see if the user has left a comment on an object: user_comment = Comment.objects.filter(content_type=self.ct, obj_id=self.oid, user=request.user) But in my

Django development work in Sydney, Australia

2006-11-27 Thread Thomas Ashelford
I'm currently looking for a Django developer to work on a substantial social-networking site based around video sharing, with a whole lot of Flickr-style smarts (mapping etc.). We are looking at about a 6 month development cycle, starting asap. The project has venture capital funding, and is

Debugging emails

2006-11-27 Thread [EMAIL PROTECTED]
I understand Django should send an email when there's an error and debug=False. It doesn't. Not for me anyway. Here's the settings: DEBUG = False TEMPLATE_DEBUG = False ADMINS = ( ('Tim Baxter', '[EMAIL PROTECTED]'), ) and that's my email. Am I missing something?

Re: Session problems

2006-11-27 Thread [EMAIL PROTECTED]
I can't speak for Jakub, but I've witnessed this, too, and I was using dreamhost and their fcgi. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to

Small comments on tutorial (improvements inside)

2006-11-27 Thread Nicolas Steinmetz
Hi, I was questionning about generic views a few days ago and I remembered it was covered on tutorial4 but as I did not have tutorial files longer on my PC, I was unable to retrieve them by memory. So to see how generic views could be handled, I had to start from tutorial 1. Therefore, I think

Re: related model in an order_by clause

2006-11-27 Thread Ivan Sagalaev
Benedict Verheyen wrote: > There are about 7 possible risks types and every risk is coupled to a > patient. Every patient has a room. > When i display all the risks of a certain type, i also need the patient > info and the room, sorted by the room. > That's why is was trying to get the roomnumber

Re: Generating docs in the djangoproject.com/documentation style

2006-11-27 Thread James Bennett
On 11/27/06, Vladimir Pouzanov <[EMAIL PROTECTED]> wrote: > Is it possible to get script that generates docs on > http://djangoproject.com/documentation? I've tried to use rst2html, > but the resulting html looks ugly even if I apply django website CSS > to it. I'm mostly interested in the right

Re: Session problems

2006-11-27 Thread Adrian Holovaty
On 11/7/06, Jakub Labath <[EMAIL PROTECTED]> wrote: > If you take a look at the attached log you will see the same child > process having the same request._req object for two different IP > addresses. Now this should not normally happen should it. The memory > address of response object also

Generating docs in the djangoproject.com/documentation style

2006-11-27 Thread Vladimir Pouzanov
Hi all, Is it possible to get script that generates docs on http://djangoproject.com/documentation? I've tried to use rst2html, but the resulting html looks ugly even if I apply django website CSS to it. I'm mostly interested in the right navigation menu ;) The website docs are very nice, but

Re: Pairing objects with two OneToOneFields

2006-11-27 Thread James Bennett
On 11/27/06, Maciej Bliziński <[EMAIL PROTECTED]> wrote: > Do you have any ideas how to solve my problem? Should the above class be > valid and should Django successfully create the tables? Or is there some > other way to map objects from two classes in 1-1 manner without creating > additional

Re: User messages framework

2006-11-27 Thread Jacob Kaplan-Moss
On 11/23/06 12:48 PM, Robert wrote: > Is there any chance to get 'message' parameter added to create/update > generic view ? > > I'm using my own views returning create_object/udpate_object and > I would like to be able to set my own "message" instaed of standard > Django create/upate messages.

Re: Inside look at Ellington?

2006-11-27 Thread Jacob Kaplan-Moss
On 11/22/06 4:19 PM, Filipe wrote: > Hi. I've also had some trouble contacting Ellington people using the > contacts on ellingtoncms.com. If someone knows a more "direct" email > address to get in touch with them I would really appreciate it. You (and anyone else) can feel free to email me

Pairing objects with two OneToOneFields

2006-11-27 Thread Maciej Bliziński
Hey Djangoers, In my first words I would like to THANK all the Django developers for such a wonderful tool! I used it all through my work on my MSc thesis. I've built a database browsing tool, a dedicated data inspection and basic analysis tools. I've also implemented a basic set algebra in

Re: djangobooks comment system

2006-11-27 Thread Jacob Kaplan-Moss
On 11/26/06 3:41 PM, Igor Guerrero Fonseca wrote: > I like the Djangobook app and the Djangobook itself so... the app is > opensource?, why dont an "DjangoPublicBook" app? Mostly because the code is still in "works-for-me" mode; it's not really ready for public consumption. I'll eventually

Re: Django + FastCGI Problems

2006-11-27 Thread Uros Trebec
On Nov 27, 6:55 pm, "Uros Trebec" <[EMAIL PROTECTED]> wrote: > ATM, if I go to "http://localhost:8484/django.fcgi; I only get "403 > Forbidden" response. OK, nevermind... I had to run "django-fcgi.py" too. http://manuals.textdrive.com/read/book/15 > Now, how do I get Apache to redirect all

Re: models as a package, admin functionality

2006-11-27 Thread Nathan R. Yergler
Uh, nevermind... I was doing: import realFile instead of: from realFile import realClass in __init__.py On Mon, 2006-11-27 at 15:37 -0500, Nathan R. Yergler wrote: > I wrote to the list a while ago about implementing models as a package > (ie, a "models" subdirectory with __init__.py, etc

models as a package, admin functionality

2006-11-27 Thread Nathan R. Yergler
I wrote to the list a while ago about implementing models as a package (ie, a "models" subdirectory with __init__.py, etc inside). As I was told then, i needed to add: class Meta: app_label='appname' to each individual model class. That worked up to getting the database API to recognize

Re: Django AMF

2006-11-27 Thread Condredge
Oooh, sweetness! Now I can switch over my RIAs from CF into Python/Django - very nice Tmohiro! Will this work with Flash MX 2004? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django users" group. To post to

Re: Flup + login problems

2006-11-27 Thread Joseph Heck
Way down at the bottom of that stacktrace it is complaining of a Template Syntax Error. You've probably borked something in your template for the URL /prihlaseni/ -joe On 11/23/06, Michal <[EMAIL PROTECTED]> wrote: > > > Hello, > I have problem with authentification. > > I have private section

Simple CAS 1.0 authentication

2006-11-27 Thread Brian Beck
Hello Djangonauts, Just offering my Django implementation of CAS 1.0 authentication backend in case anyone else is trying to use it. (CAS is a single sign-on protocol, you can read about it here: http://www.ja-sig.org/products/cas/index.html) It's a little trickier to implement than other

Re: Multi-database sample

2006-11-27 Thread [EMAIL PROTECTED]
I ended up posting a sample on the wiki page for this branch. I have the whole site done using raw python and mysqldb... but we wanted to switch to django and use it to gen our objects for us...to go with a more OO design..as the site has grown and we are finding it harder to maintain. I was

Re: Submission rejected as potential spam (Akismet says content is spam)

2006-11-27 Thread Don Arbow
On Nov 27, 2006, at 5:29 AM, favo wrote: > I can't submit or change ticket, this block me to contrib. could we > fix > the problem of the ticket system? I heard someones have the same > problem. thanks a lot. Did you click the settings link at the bottom right of the page and enter your

Re: html templates for generic views

2006-11-27 Thread [EMAIL PROTECTED]
i got a app in svn you can check out svn co http://fivethreeo.dynalias.org/repos/fivelib/ u: public p: public --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send

html templates for generic views

2006-11-27 Thread phess
I must quickly develop a complete website, so I chose "the Web framework for perfectionists with deadlines". ;) In my first tests with a web-based registration mechanism, I'd like to use default (could be quick n' dirty) templates, but these seem to be unavailable. Since I'm really not

Re: Re: Django + FastCGI Problems

2006-11-27 Thread Uros Trebec
On 11/27/06, Gábor Farkas <[EMAIL PROTECTED]> wrote: > >> If anyone has questions about how to do this let me know. > > > > > > I for one, would VERY MUCH like to know how to do that. > > > > My django app has a downtime of 2 weeks now, because of the "incomplete > > headers" :( > > and btw. are

Re: Hard coded instances of model classes

2006-11-27 Thread Derek Hoy
I am doing something a little similar, although actually the site is about what you would call 'scale development', so the resulting forms aren't used for data collection. But maybe it's of interest? I use xml to define a template, composed of elements and groups. The xml is just stored in a

Re: related model in an order_by clause

2006-11-27 Thread Benedict Verheyen
>> So now for almost all my models i have an extra manager class with a >> custom sql that gets the room number so i can sort on the room number. > > Too much of custom SQL may be an evidence of wrong model design or an > evidence of bad support of this particular usecase in Django. Usually >