Django + newforms + jQuery

2007-07-11 Thread Przemek Gawronski
Hi, any one willing to share some examples of django newforms with jQuery? Thanks in advance! Przemek -- AIKIDO TANREN DOJO - Poland - Warsaw - Mokotow - Ursynow - Natolin info: http://www.tanren.pl/ phone: +4850151 email: [EMAIL PROTECTED] --~--~-~--~~~---~-

Re: case sensitive usernames

2007-07-11 Thread Mike H
Oh boy, lack of sleep made me get my examples mixed up a little. Obviously to any half awake mind, the 'Neil' with an L and the 'NeiI' with an i example is irrelevant. However, a 'neil' 'Neil' situation could sitll arise, with a per user slug prone to problems in that case. Lesson for today

Re: Graphs and django

2007-07-11 Thread Toby Dylan Hocking
Hey Jeremy, Thanks for the input. You are correct: I am running a recent copy of django from SVN on the primary machine I am using to develop django.contrib.dataplot. In fact, I ran into the same problem that you did when I tried to port django.contrib.dataplot to a different machine -- a mac

Re: Graphs and django

2007-07-11 Thread Toby Dylan Hocking
Hi Ben, I see what you're doing now. There are a couple things I should mention. First of all, you are right: getattr(r,'generic.scatter.plot') is not the same as typing r.generic.scatter.plot -- instead, it invokes the __getattr__ method of r, and looks for something by that name in the R na

Re: Which database is better for django, PostgreSQL or MYSQL?

2007-07-11 Thread Michael Radziej
On Thu, Jul 12, Kenneth Gonsalves wrote: > > > On 12-Jul-07, at 6:45 AM, nick feng wrote: > > > Which database is better for django, PostgreSQL or MYSQL? > > postgresql - general, not for django in particular mysql does not support django fixtures (unless you use the ISAM storage engine in m

Re: Django & Amazon (SOAP)

2007-07-11 Thread Jeremy Dunck
On 7/11/07, Justin Lilly <[EMAIL PROTECTED]> wrote: > > Hey all. I'm trying to play around with API's and I wanted to tap into > Amazon's to get book listings. I'm not sure what this has to do with Django. > The problem is that when I search for > "python" in books, only 2/5ths of the results ac

Django & Amazon (SOAP)

2007-07-11 Thread Justin Lilly
Hey all. I'm trying to play around with API's and I wanted to tap into Amazon's to get book listings. The problem is that when I search for "python" in books, only 2/5ths of the results actually have to do with Python. This isn't the case when I search on Amazon itself. Any thoughts on what might

Re: Template variable when None displays None

2007-07-11 Thread Nathan Ostgard
It's the default behavior of Python: >>> str(None) 'None' I don't agree that it should be the default. None and "" are two distinct values -- especially with a database. In databases, None (or NULL) normally represents a _missing_ value, whereas a "" is one that was intentionally specified to be

Re: Graphs and django

2007-07-11 Thread Ben Ford
Hi Toby, My versions are: R:2.4.0 Python: 2.5.1 Rpy:1.0-RC2 Sorry I wasn't very clear earlier... I imported r into ipython to have a play with it and see what happens. I tried getattr(r,' generic.scatter.plot') which didn't work - I'm under the impression that getattr won't w

case sensitive usernames

2007-07-11 Thread mike
Hi all, While I was writing test cases for my upcoming website, I noticed I that the contrib.auth module will happily make a user called Mike and user called mike and treat them as two separate users. Are there reasons for this? I patched my installation of django so that usernames were not cas

Re: session in all templates?

2007-07-11 Thread Russell Keith-Magee
On 7/12/07, Martin Kaffanke <[EMAIL PROTECTED]> wrote: > At the moment I use on some places a > > {'session': request.session} for the Context to render the template. > How Can I make the session automaticaly available in the base template, > without having to be aware that I don't forgett this pa

Re: Which database is better for django, PostgreSQL or MYSQL?

2007-07-11 Thread Kenneth Gonsalves
On 12-Jul-07, at 6:45 AM, nick feng wrote: > Which database is better for django, PostgreSQL or MYSQL? postgresql - general, not for django in particular -- regards kg http://lawgon.livejournal.com http://nrcfosshelpline.in/web/ --~--~-~--~~~---~--~~ You re

Re: Site framework

2007-07-11 Thread Russell Keith-Magee
On 7/11/07, Glebb <[EMAIL PROTECTED]> wrote: > > Hi, I'm trying to use the site framework, and it works, but I just > have one problem. I have a form (from form_for_model for example) > which represents an object which has a site foreign key. The site > selection shows up just fine in the form. Bu

Re: newforms-admin character encoding problem

2007-07-11 Thread leifbyron
£,¥ and other non-ASCII symbols are working perfectly on the latest newforms-admin. Thanks, Malcolm! --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-

Re: Generating graphs from db data and displaying results using Django?

2007-07-11 Thread Toby Dylan Hocking
Thanks for the input, Jeremy. I'd definitely be open to using PIL instead of ImageMagick. django.contrib.dataplot use of ImageMagick is relatively simple: taking vector PDFs drawn in R and converting them to fullscreen and thumbnail raster PNGs. Do you know of a way that PIL can be used to con

Re: avoiding 'matching query not exist'

2007-07-11 Thread James Bennett
On 7/11/07, Carl Karsten <[EMAIL PROTECTED]> wrote: > Huh. I would have expected this case would have been provided for. No, the raising of the exception is quite deliberate on Django's part -- when you use a method which is expected to return one and only one object, Django has only two options

Which database is better for django, PostgreSQL or MYSQL?

2007-07-11 Thread nick feng
Which database is better for django, PostgreSQL or MYSQL? --~--~-~--~~~---~--~~ 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 thi

Re: Template variable when None displays None

2007-07-11 Thread Rand Bradley
The default_if_none filter was not working when I tried it the first time, but I retried it after your post and it is working so this may solve my issue. Is that the designed behavior template variables? If the value is None, display the word "None"? So someone has to use the default_if_none filt

Re: Generating graphs from db data and displaying results using Django?

2007-07-11 Thread Jeremy Dunck
On 7/11/07, Toby Dylan Hocking <[EMAIL PROTECTED]> wrote: > general enough to handle several different backend > plotting languages, such as matplotlib, pil, octave, How hard would it be to depend on PIL rather than ImageMagick? I'm asking because Django already requires PIL if you want ImageFie

Re: Graphs and django

2007-07-11 Thread Jeremy Dunck
On 7/11/07, Toby Dylan Hocking <[EMAIL PROTECTED]> wrote: > If you still need help with making data-driven plots, why don't you check > out my new Django package --- I'd like some testers and comments. Initial reaction-- sweet! After linking dataplot into my contribs dir and adding both dataplot

Re: Generating graphs from db data and displaying results using Django?

2007-07-11 Thread Toby Dylan Hocking
You guys should definitely check my new framework for making data-driven plots with Django (installation instructions in INSTALL.txt): http://www.ocf.berkeley.edu/~tdhock/dataplot-0.2.tgz So far django.contrib.dataplot only uses the R programming language to generate images server-side, but th

Re: When I POST, it tells me connection was reset while page was loading

2007-07-11 Thread Luke
On some investigation, I found this: http://code.djangoproject.com/ticket/3089 and this http://code.djangoproject.com/ticket/3496 but this happens to me no matter what (at least with firefox). It's fine in IE6 On Jul 11, 5:11 pm, Luke <[EMAIL PROTECTED]> wrote: > I just set up my first django de

Re: How to execute an external application from View

2007-07-11 Thread RayLeyva
On Jul 8, 11:54 pm, Knut Ivar Nesheim <[EMAIL PROTECTED]> wrote: > A working workaround: > If javascript is an option, have a look at this: http:// > developer.yahoo.com/yui/examples/container/panelwait/1.html Knut, Thanks for the great idea, and I'll definitely dig deeper into it if for no ot

When I POST, it tells me connection was reset while page was loading

2007-07-11 Thread Luke
I just set up my first django development site and I'm developing it with the dev server. I just set up my first form. It works the first time, but each subsequent time, it tells me that the connection was reset while the page was loading. If I kill the dev server and manage.py runserver again, it

Re: Graphs and django

2007-07-11 Thread Toby Dylan Hocking
Hi Ben, I'm excited to hear that you got a copy of django.contrib.dataplot and you are trying it out. I will try to help you debug the problem, but the full traceback may be more useful. Can you send it? The purpose of the get_r_fun method is to look at the current R environment and check if

Template variable when None displays None

2007-07-11 Thread Rand Bradley
When a template variable value is None, is it expected to render the word 'None'? I would expect this to fail silently instead of displaying the word. Is there a configuration setting or some way to change the default rendering? Do I have to wrap variables with an {% if ... %} in order to not displ

RE: Template variable when None displays None

2007-07-11 Thread Chris Brand
When a template variable value is None, is it expected to render the word 'None'? I would expect this to fail silently instead of displaying the word. Is there a configuration setting or some way to change the default rendering? Do I have to wrap variables with an {% if ... %} in order to not displ

www.OutpatientSurgicare.com/video/

2007-07-11 Thread dvd_km
www.OutpatientSurgicare.com/video/ Outpatient Doctors Surgery Center is committed to offering the healthcare the community needs. We offer patients a meaningful alternative to traditional surgery. This state-of-the-art outpatient surgery center, located in the heart of Orange County, at 10900 Warn

Is there any way to custom group models in the admin panel?

2007-07-11 Thread Sebastian Macias
By default models are grouped by app. I really need to be able to break down that grouping a little bit more. I will have an app with probably 40-50 models and would like to group those logically instead of having them all listed under my app name. Thanks, Sebastian --~--~-~--~~---

Re: Object list generic view + list

2007-07-11 Thread Drasty
Have you tried using the http://www.djangoproject.com/ documentation/db-api/#order-by-fields">order_by method on your queries? Even though it may get cumbersome, you could also add something along these lines to your url.py file for each specific query you might want to call: def some_list():

Re: new django site: PotterPredictions.com

2007-07-11 Thread Carl Karsten
Kai Kuehne wrote: > Well, I meant without to register myself on the site. in case it isn't crystal clear: http://www.codinghorror.com/blog/archives/000881.html "Removing The Login Barrier" Carl K --~--~-~--~~~---~--~~ You received this message because you are su

Re: new django site: PotterPredictions.com

2007-07-11 Thread Dennis Allison
http://www.potterpredictions.com returns "Site not configured' whereas http://potterpredictions.com takes you to content. On Wed, 11 Jul 2007, Kai Kuehne wrote: > > Hi James, > > On 7/11/07, James Tauber <[EMAIL PROTECTED]> wrote: > > > > Django users might be interested in my lastest

Re: new django site: PotterPredictions.com

2007-07-11 Thread Kai Kuehne
Well, I meant without to register myself on the site. Sorry if that was confusing. --~--~-~--~~~---~--~~ 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.

Re: new django site: PotterPredictions.com

2007-07-11 Thread Kai Kuehne
Hi James, On 7/11/07, James Tauber <[EMAIL PROTECTED]> wrote: > > Django users might be interested in my lastest django-based website: > http://PotterPredictions.com/ which allows people to record their > predictions of what will be revealed in the final Harry Potter book, > compare with friends

Re: avoiding 'matching query not exist'

2007-07-11 Thread Carl Karsten
James Bennett wrote: > On 7/11/07, Carl Karsten <[EMAIL PROTECTED]> wrote: >> How can I do something similar with: >> coursestatus = Event.objects.filter( >>eventtype__eventcode='corsecond', >>eventdate__lt = datetime.now() >>).latest('eventdate') >> >> Currently I get

Re: avoiding 'matching query not exist'

2007-07-11 Thread James Bennett
On 7/11/07, Carl Karsten <[EMAIL PROTECTED]> wrote: > How can I do something similar with: > coursestatus = Event.objects.filter( >eventtype__eventcode='corsecond', >eventdate__lt = datetime.now() >).latest('eventdate') > > Currently I get " Event matching query does n

avoiding 'matching query not exist'

2007-07-11 Thread Carl Karsten
This deals with empty sets: dinner_special = Event.objects.filter( eventtype__eventcode='restspec', eventdate = datetime.now() ) Today's Dinner Secials: {% if dinner_special %} {{ dinner_special.0.title }}{{ dinner_special.0.description }} {% else %}

Re: DRY violation

2007-07-11 Thread Aidas Bendoraitis
Use the pre_save signal. Write something like the following into some models.py file: from django.dispatch import dispatcher def attach_user_to_object(sender, instance, signal, *args, **kwargs): # sender - the model which instance is being saved # instance - the instance being saved

Re: saving many2many relations

2007-07-11 Thread RajeshD
Hi, > Anyone knows where the problem is? If you are using the Admin app to populate tags then the automatic manipulators first call Receta.save() followed by setting the models M2M field. This wipes out your changes to etiquetas inside Receta.save() One solution is to add get_tags and set_tags

Direct Client - Sr.Soft Engineer-Python and Linux

2007-07-11 Thread Kan
Hello, We have requirement for Sr.Software Engineer in San Jose CA with very strong experinece in PYTHON AND LINUX . If your skills and experience matches with the same, send me your resume asap with contact # and rate. Locals only pls apply The details of the openings are:- Strong in Python a

Re: session in all templates?

2007-07-11 Thread Chris Hoeppner
Martin Kaffanke escribió: > Am Mittwoch, den 11.07.2007, 13:34 -0400 schrieb Simon Drabble: >> On Wed, 11 Jul 2007, Martin Kaffanke wrote: >> >>> Am Mittwoch, den 11.07.2007, 12:26 -0400 schrieb Simon Drabble: On Wed, 11 Jul 2007, Martin Kaffanke wrote: > Hi there! > > How ca

Part time tech writers wanted - 2 positions work from anywhere

2007-07-11 Thread techhairball
Please visit http://www.TechHairBall.com for more info. Any thing related with technology will work. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-

Re: session in all templates?

2007-07-11 Thread Martin Kaffanke
Am Mittwoch, den 11.07.2007, 13:34 -0400 schrieb Simon Drabble: > On Wed, 11 Jul 2007, Martin Kaffanke wrote: > > > Am Mittwoch, den 11.07.2007, 12:26 -0400 schrieb Simon Drabble: > >> On Wed, 11 Jul 2007, Martin Kaffanke wrote: > >> > >>> Hi there! > >>> > >>> How can I configure django to put th

Re: Eclipse and PyDev setup

2007-07-11 Thread Jacob Kaplan-Moss
HI Fred -- In the future, please don't cross-post to django-users and django-dev; django-dev is used to discuss the development of Django itself, not to answer usage questions. Thanks! Jacob --~--~-~--~~~---~--~~ You received this message because you are subscri

threadlocals in Manager, import-time vs. execution-time problem?

2007-07-11 Thread Nathaniel Whiteinge
I'm having a problem with threadlocals in a custom manager making queries for the wrong user. I've Googled around quite a bit, and haven't found the answer -- except others *do* seem to be successfully using threadlocals in Managers. Ostensibly this is a import-time vs. execution-time problem, but

newforms: manually accessing initial value for field

2007-07-11 Thread Chris Hoeppner
Hi there! I was just wondering how to access the value I've set in the view with Form(initial={'val':somevar}) in the template. Maybe field.value? No. field.initial? No. Any clues? Thanks! --~--~-~--~~~---~--~~ You received this message because you are subscrib

new django site: PotterPredictions.com

2007-07-11 Thread James Tauber
Django users might be interested in my lastest django-based website: http://PotterPredictions.com/ which allows people to record their predictions of what will be revealed in the final Harry Potter book, compare with friends and then ultimately (after July 21st) find out who got the most things co

Re: newforms-admin: defaults and radio select

2007-07-11 Thread leifbyron
Hey Allen -- Any luck? --~--~-~--~~~---~--~~ 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 [EMAIL P

Object list generic view + list

2007-07-11 Thread Vincent Foley
Hello, I have a small problem in an application. I use a generic view to display a list of files. Each file has a category and a faculty, both of which are foreign key. I want to be able to sort by the name of the file, the name of the category or the name of the faculty. The problem is that

Re: session in all templates?

2007-07-11 Thread Simon Drabble
On Wed, 11 Jul 2007, Martin Kaffanke wrote: > Am Mittwoch, den 11.07.2007, 12:26 -0400 schrieb Simon Drabble: >> On Wed, 11 Jul 2007, Martin Kaffanke wrote: >> >>> Hi there! >>> >>> How can I configure django to put the session (request.session) in all >>> templates? >>> >>> I want to put a 'Hell

Re: session in all templates?

2007-07-11 Thread Martin Kaffanke
Am Mittwoch, den 11.07.2007, 12:26 -0400 schrieb Simon Drabble: > On Wed, 11 Jul 2007, Martin Kaffanke wrote: > > > Hi there! > > > > How can I configure django to put the session (request.session) in all > > templates? > > > > I want to put a 'Hello Username' for logged in Users, and I want to do

Re: Update in django custom sql

2007-07-11 Thread Dannoo
Tim, Actually thanks! Once I put it into a function with the @transaction.commit_manually decoration and manually commited: it worked fine. Thanks again, Dan On Jul 11, 11:32 am, Dannoo <[EMAIL PROTECTED]> wrote: > I tried that and got "serialized connection: cannot commit on this > cursor" > A

Re: Generating graphs from db data and displaying results using Django?

2007-07-11 Thread Vincent Nijs
http://www.scipy.org/Cookbook/Matplotlib/Django On 7/11/07 12:06 PM, "Forest Bond" <[EMAIL PROTECTED]> wrote: > On Wed, Jul 11, 2007 at 04:56:03PM -, [EMAIL PROTECTED] wrote: >> >> I would actually suggest using Django to create a web service to get >> the data, and a JavaScript charting li

Re: Generating graphs from db data and displaying results using Django?

2007-07-11 Thread Forest Bond
On Wed, Jul 11, 2007 at 04:56:03PM -, [EMAIL PROTECTED] wrote: > > I would actually suggest using Django to create a web service to get > the data, and a JavaScript charting library to do the drawing client- > side. Why not create the graphs on the server? -Forest signature.asc Description

Re: Generating graphs from db data and displaying results using Django?

2007-07-11 Thread [EMAIL PROTECTED]
I would actually suggest using Django to create a web service to get the data, and a JavaScript charting library to do the drawing client- side. A great one is PlotKit (http://www.liquidx.net/plotkit/) A (very) simple example of how this could look is on my personal website http://www.eflorenzan

Re: session in all templates?

2007-07-11 Thread Simon Drabble
On Wed, 11 Jul 2007, Martin Kaffanke wrote: > Hi there! > > How can I configure django to put the session (request.session) in all > templates? > > I want to put a 'Hello Username' for logged in Users, and I want to do a > dynamic login/logout button into the menu, depends on if there is a > logg

Re: ForeignKey(User, list_display=full?

2007-07-11 Thread Nathan Ostgard
I really think you should define a custom field and override the choices. For example: from django.utils.encoding import smart_unicode class UserForeignKey(models.ForeignKey): def get_choices(self, include_blank=True, blank_choice=models.BLANK_CHOICE_DASH): "Returns a list of tuples used as

Re: how to set language explicitly in multi-lingual site

2007-07-11 Thread Amit Ramon
ׁHi, As Malcolm pointed out, you'll have to use something like the third party multilingual framework for translating the database stuff. You can find it at http://code.google.com/p/django-multilingual/ Good luck, Amit ביום רביעי 11 יולי 2007, 12:06, נכתב על ידי Matt Davies: > Hi Amit, Malco

Re: Problem accessing ManyToManyField

2007-07-11 Thread Shankar
On Wed, 11 Jul 2007 16:30:48 +1000, Malcolm Tredinnick wrote: >> On Wed, 11 Jul 2007 11:27:59 +0800, Russell Keith-Magee wrote: > [...] >> > - What happens when you run the following: from >> > django.contrib.auth.models import User print User.objects.all[0] >> :: >> output from pytho

Re: Update in django custom sql

2007-07-11 Thread Dannoo
I tried that and got "serialized connection: cannot commit on this cursor" Also tried close with no results. On Jul 11, 11:29 am, Tim Chase <[EMAIL PROTECTED]> wrote: > > I am wondering why does this code does not work. The sql runs fine > > fine when executed through the postgres admin. > >

Re: Eclipse and PyDev setup

2007-07-11 Thread Lic. José M. Rodriguez Bacallao
Hi, I'm using Eclipse with pydev for development too. My suggestions for a project is to create a pydev project without the src folder. later, U have to tell eclipse in the project properties that your workspace is a source folder and is an external source folder too. On 7/11/07, Petra Javornicka

Re: Update in django custom sql

2007-07-11 Thread Tim Chase
> I am wondering why does this code does not work. The sql runs fine > fine when executed through the postgres admin. > > from django.db import connection > > cursor = connection.cursor() > x = cursor.execute("UPDATE videos_video SET name = 'Please work' > WHERE videos_video.id = 1; " ) I kno

Re: MySQL Got packet bigger than 'max_allowed_packet'

2007-07-11 Thread [EMAIL PROTECTED]
Hi fixed the problem mysql for python 1.2.2 did the trick http://sourceforge.net/project/showfiles.php?group_id=22307&package_id=15775 Thanks again Owen On Jul 8, 9:33 pm, "[EMAIL PROTECTED]" <[EMAIL PROTECTED]> wrote: > Hello > > I wrote a test case using mysldb with direct python calls and us

Update in django custom sql

2007-07-11 Thread Dannoo
I am wondering why does this code does not work. The sql runs fine fine when executed through the postgres admin. from django.db import connection cursor = connection.cursor() x = cursor.execute("UPDATE videos_video SET name = 'Please work' WHERE videos_video.id = 1; " ) Any help thoughts wou

Re: Eclipse and PyDev setup

2007-07-11 Thread Rogelio
Hi, I'm a newbie as well, but have a project I developed using Eclipse and Pydev. Bascially, I just unchecked the "Create src folder" option for the Pydev project and all seems OK so far. Can't help with Apache yet as I just use the Django builtin server from within Eclipse and start/stop the se

Re: Eclipse and PyDev setup

2007-07-11 Thread Petra Javornicka
> I'm a django newbie, just finished the tutorial. I would like to do my > development under Eclipse. PyDev want to have a "src" folder under the > project, which does not really fit the django default directory structure. I'm a Django newbie as well and I've had a similiar/same problem. Origin

Django live chat app?

2007-07-11 Thread [EMAIL PROTECTED]
Does anyone know of a live chat app for Django, or have any suggestions on how to go about integrating live chat into a Django- based site? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django users" group. To po

Site framework

2007-07-11 Thread Glebb
Hi, I'm trying to use the site framework, and it works, but I just have one problem. I have a form (from form_for_model for example) which represents an object which has a site foreign key. The site selection shows up just fine in the form. But when I try to submit it, it complains about the site_

Re: psycopg2 and django issue.. (again)

2007-07-11 Thread Etienne Robillard
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Malcom, The steps to repeat this problem is simply to invoke 'syncdb' using either django-admin.py and/or manage.py, on a fresh database: 1. export PYTHONPATH=`pwd`:/path/to/django (optional) 2. sudo dropdb -U db_user db_name 3. sudo createdb -U

Eclipse and PyDev setup

2007-07-11 Thread Sells, Fred
I'm using Eclipse 3.2 and latest PyDev. I'm a django newbie, just finished the tutorial. I would like to do my development under Eclipse. PyDev want to have a "src" folder under the project, which does not really fit the django default directory structure. mysite (an Elcipse project) poll

أرجو منكم مساعدتي لتحسين ألكمبيوتر ألخاص بي لأنني موظف متقاعد ومبتدي في ألأنترنيت

2007-07-11 Thread abumajed
أنا كنت سابقا موظفا وألآن متقاعد فوجدت إن ألوسيله أللتي أقضي بها فراغي هي ألأنترنيت طبعا بعد نصائح من أصدقاء إضافةإلى ذلك إنني رجل أعزب وألمشكله ألكبيره أللتي أواجهها هي ضعف لغتي ألإنجليزيه وطبعا استعمالي في المنزل ولا يكون بجواري من يساعدني على ترجمة اللغه ألإنجليزيه فأستعمن ببرنامج ألترجمه ولكنه

session in all templates?

2007-07-11 Thread Martin Kaffanke
Hi there! How can I configure django to put the session (request.session) in all templates? I want to put a 'Hello Username' for logged in Users, and I want to do a dynamic login/logout button into the menu, depends on if there is a logged in user or not. Thanks, Martin signature.asc Descripti

Re: Problem in current svn TRUNK

2007-07-11 Thread Peter Nixon
On Wed 11 Jul 2007, Michael Radziej wrote: > Hi, > > you're using the alpha version of SuSE ... well ... there might very well > be a problem very deep in one of the libraries. The alpha releases aren't > very reliable. I'd suggest that you try it with another OS. Hi Michael While I agree that t

Re: Django Book Ch3 error

2007-07-11 Thread Jeremy Dunck
On 7/11/07, Thomas Guettler <[EMAIL PROTECTED]> wrote: > > Hi, > > I had the same error. Today, after "svn update" it worked. > Right, see this ticket: http://code.djangoproject.com/ticket/4823 It wasn't a book error; it was a Python 2.3 incompatibility bug. --~--~-~--~~

Re: Problem in current svn TRUNK

2007-07-11 Thread Michael Radziej
Hi, you're using the alpha version of SuSE ... well ... there might very well be a problem very deep in one of the libraries. The alpha releases aren't very reliable. I'd suggest that you try it with another OS. So long, Michael -- noris network AG - Deutschherrnstraße 15-19 - D-90429 Nürnb

Re: some problems when django worked under fastcgi..

2007-07-11 Thread KpoH
edit ./manage.py #!/usr/bin/env python replace with #!/usr/local/bin/python 萧连衣 пишет: > > http://www.djangoproject.com/documentation/0.96/fastcgi/ > To easily restart your FastCGI daemon on Unix, try this small shell > script: > #!/bin/bash > > # Replace these three settings. > PROJDIR="/home/us

Re: DRY violation

2007-07-11 Thread Norjee
Use the events framework. I'm sure there is a pre-save event. Use it to execute one (DRY) method and attach it to all your models. I personally would just write a custom method (your custom attach_user_to_model), which I'd call in all the save methods of the models.. But I guess attaching evenen

DRY violation

2007-07-11 Thread Lic. José M. Rodriguez Bacallao
Hi people, I got a little problem with the DRY principle. I have a lot of models with a common attribute: created_by, which is an attribute to store the user who created that object but, in all my models I have to define the save() method over and oven again to store the user manually before django

DRY violation

2007-07-11 Thread Lic. José M. Rodriguez Bacallao
Hi people, I got a little problem with the DRY principle. I have a lot of models with a common attribute: created_by, which is an attribute to store the user who created that object but, in all my models I have to define the save() method over and oven again to store the user manually before django

Re: Calling different Django sites from the same external application

2007-07-11 Thread Robin Becker
Hancock, David (DHANCOCK) wrote: > We have two Django "projects" with distinct settings files, and we need to > be able to make API calls to each of them from the same (separate) > long-running application. Using the API of one of them is easy--we've got > the DJANGO_SETTINGS_MODULE defined in the

Django on a shared host. The docs are scaring me ;)

2007-07-11 Thread AndyB
Despite having three live Django sites running from Apache and FCGI I have always felt there was a certain degree of black magic about the process and I've succeeded only by following instructions and keeping my fingers crossed. Quite often the process takes several hours of fiddling and it seems

Re: Problem in current svn TRUNK

2007-07-11 Thread Marijn Vriens
Yesterday I saw this bug as well when working with a new project and Django trunk. For me it went away when I changed settings.py from: DATABASE_ENGINE = 'postgresql_psycopg2' to DATABASE_ENGINE = 'postgresql' Regards, Marijn Vriens. On 7/11/07, Peter Nixon <[EMAIL PROTECTED]> wrote: > > > Hi

Re: Problem in current svn TRUNK

2007-07-11 Thread Peter Nixon
Hi Paul The problem was described (as much as it is possible to) in the initial mail to the users list as well as below in the test requested by Russell. Basically django simply exists whenever it gets data based from postgresql.. anywhere. syncdb, inspecdb, /admin/ and everything else that ac

error: package directory '\django' does not exist

2007-07-11 Thread itajit
Hi, I'm trying to install Django on windows platform. As I tried to run its setup file it gives an error msg that "error: package directory '\django' does not exist" as there is directory in the folder Django-0.96. So, will u plz help me out from this its urgent. Thanx in advance for ur upco

Re: Django Book Ch3 error

2007-07-11 Thread Thomas Guettler
Hi, I had the same error. Today, after "svn update" it worked. Thomas Am Dienstag, 10. Juli 2007 08:59 schrieb SM: > Hmmm. As a last resort I replaced the SVN (0.97) version of Django > with the 0.96 version and now it seems to work fine. Very strange, but > I'm relieved to have 'fixed' it. >

error: package directory '\django' does not exist

2007-07-11 Thread [EMAIL PROTECTED]
Hi, I'm trying to install Django on windows platform. As I tried to run its setup file it gives an error msg that "error: package directory '\django' does not exist" as there is directory in the folder Django-0.96. So, will u plz help me out from this its urgent. Thanx in advance for ur upcom

smtp error

2007-07-11 Thread Chris Hoeppner
Hey there! I'm getting a quite weird smtp error when sending mail. Here's a traceback: Traceback (most recent call last): File "/usr/lib/python2.5/site-packages/django/core/handlers/base.py" in get_response 77. response = callback(request, *callback_args, **callback_kwargs) File "/var/www/dj

Problem with post_syncdb signal and its processing

2007-07-11 Thread [EMAIL PROTECTED]
Hi all, I need to create my own user groups and associated required permissions. Honza Kral in Czech Django forum has adviced me to handle post_syncdb signal in my Django application. It seemed to be an ideal solution, but I recognized that I am not able to work with permissions in my post_syncdb

Calling different Django sites from the same external application

2007-07-11 Thread Hancock, David (DHANCOCK)
We have two Django "projects" with distinct settings files, and we need to be able to make API calls to each of them from the same (separate) long-running application. Using the API of one of them is easy--we've got the DJANGO_SETTINGS_MODULE defined in the environment of the calling process, and i

Re: Problem in current svn TRUNK

2007-07-11 Thread Peter Nixon
Cross posted to -devel as this is definitely a bug On Wed 11 Jul 2007, Peter Nixon wrote: > On Wed 11 Jul 2007, Russell Keith-Magee wrote: > > On 7/10/07, Peter Nixon <[EMAIL PROTECTED]> wrote: > > > How can I debug this in a way that will provide the developers with > > > more usefull info?

Re: multiple inner joins in sql

2007-07-11 Thread novice
cool, the underscore seems to be the problem. Now to the second question. What will be the best way to do this? I mean to get the top N categories with the most offers, and from this top categories get the top M offers that have the highest percentage discount, that is what my not so nice SQL sta

Re: saving many2many relations

2007-07-11 Thread zenx
Thank you Collin, I tried that before posting in this group but the same thing happened: I get no errors when saving but Tags still remain not asociated with Receta. class Receta(models.Model): def save(self): from django.template.defaultfilters import slugify tags = se

Re: how to set language explicitly in multi-lingual site

2007-07-11 Thread Kenneth Gonsalves
On 11-Jul-07, at 2:36 PM, Matt Davies wrote: > On the fly I guess I mean no -- regards kg http://lawgon.livejournal.com http://nrcfosshelpline.in/web/ --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django u

Re: how to set language explicitly in multi-lingual site

2007-07-11 Thread Malcolm Tredinnick
On Wed, 2007-07-11 at 10:06 +0100, Matt Davies wrote: > Hi Amit, Malcolm > > We're about to build a site that needs english/welsh transation. > > Does django.utils.translation.activate() translate from one Language > to another without having to have both languages as text in a > database? Djan

Re: how to set language explicitly in multi-lingual site

2007-07-11 Thread Matt Davies
Hi Amit, Malcolm We're about to build a site that needs english/welsh transation. Does django.utils.translation.activate() translate from one Language to another without having to have both languages as text in a database? On the fly I guess I mean. vander. On 11/07/07, Amit Ramon <[EMAIL PROT

Re: Problem in current svn TRUNK

2007-07-11 Thread Peter Nixon
On Wed 11 Jul 2007, Russell Keith-Magee wrote: > On 7/10/07, Peter Nixon <[EMAIL PROTECTED]> wrote: > > How can I debug this in a way that will provide the developers with more > > usefull info? > > The best way to help us debug this would be to produce a minimal > example that replicates the prob

Re: Graphs and django

2007-07-11 Thread Ben Ford
Hi Toby I've grabbed a copy of your code but the RPlot.get_r_fun method isn't working for me... Could you perhaps explain how it does the mapping to the R function? What my testing is saying to me is that r (the one that's imported at the top of __init__.py) has no attribute generic... I've had a v

some problems when django worked under fastcgi..

2007-07-11 Thread 萧连衣
http://www.djangoproject.com/documentation/0.96/fastcgi/ To easily restart your FastCGI daemon on Unix, try this small shell script: #!/bin/bash # Replace these three settings. PROJDIR="/home/user/myproject" PIDFILE="$PROJDIR/mysite.pid" SOCKET="$PROJDIR/mysite.sock" cd $PROJDIR if [ -f $PIDFILE

Re: multiple inner joins in sql

2007-07-11 Thread cesco
Thanks:-) On Jul 11, 3:10 am, Nathan Ostgard <[EMAIL PROTECTED]> wrote: > On Jul 10, 2:58 pm, novice <[EMAIL PROTECTED]> wrote: > > > but I get error that the offers_offerprice.offerseller_id column > > doesnt exist. > > I think you're missing an underscore. Your model has the field named > offer

Re: Graphs and django

2007-07-11 Thread Toby Dylan Hocking
Hi there, If you still need help with making data-driven plots, why don't you check out my new Django package --- I'd like some testers and comments. Basically it is an interface to the R programming language (for statistics and graphics) through the RPy package. You can download my latest rel

  1   2   >