Re: Bug with regroup ? (which does not regroup as he shoud / I hope...)

2007-06-18 Thread Nicolas Steinmetz
Florian Apolloner a écrit : > I am not quite sure wheter my answer is correct, as you didn't post > your view, My view is quite simple : # Display the detail for a given CV def cv_detail(request, firstname, lastname): user = User.objects.get(first_name=firstname, last_name=lastname) u

Re: CSS on dev server, same old problem

2007-06-18 Thread AnaReis
On Jun 15, 5:22 pm, alg <[EMAIL PROTECTED]> wrote: > > > I can see the css files code on the web browser > > through:http://145.23.6.135:8000/manager/appsmedia/css/css1.css > > You're using an absolute path in the link element's href. Hum... How do I use a dynamic path? (Sorry if it's a lame

Re: Survey: FileBrowser and FancyUpload

2007-06-18 Thread patrick k.
thanks for the feedback so far. I´m just waiting, if there´s more feedback. so far, it´s very clear that the integration of fancyupload is disliked. thanks, patrick Am 16.06.2007 um 17:54 schrieb itsnotvalid: > > By the way I like the idea of Gmail upload methods too. > But a flash plugin co

Re: get subversion revision-number in a django-project

2007-06-18 Thread Frank Tegtmeyer
"Joseph Heck" <[EMAIL PROTECTED]> writes: > generally invoking "svnversion" is the easiest way to get this. This works only if you are not using an export. What works there also is keyword replacement (LastChangedRevision). Unfortunately you have to change the file that tracks the revision for u

Re: CSS on dev server, same old problem

2007-06-18 Thread Vincent Nijs
I think it should work if you use: (r'^appsmedia/(?P.*)$', 'django.views.static.serve', {'document_root': '/nobackup/reis/Project/Manager/templates/ appsmedia'}), On the template: Or (r'^manager/appsmedia/(?P.*)$', 'django.views.static.serve', {'document_root': '/nobackup/reis/Project/Manager

Re: Survey: FileBrowser and FancyUpload

2007-06-18 Thread Dirk van Oosterbosch, IR labs
I think to have a progress bar is a *big* pro, but if Flash could be avoided, I would be happy too. my $0.02 dirk On 18-jun-2007, at 10:42, patrick k. wrote: > > thanks for the feedback so far. I´m just waiting, if there´s more > feedback. > > so far, it´s very clear that the integration of f

Re: CSS on dev server, same old problem

2007-06-18 Thread AnaReis
It works Thank you so much! :D On Jun 18, 10:52 am, Vincent Nijs <[EMAIL PROTECTED]> wrote: > I think it should work if you use: > > (r'^appsmedia/(?P.*)$', 'django.views.static.serve', > {'document_root': '/nobackup/reis/Project/Manager/templates/ > appsmedia'}), > > On the template: > > >

Re: Problems with running Django on a remote machine

2007-06-18 Thread Dirk van Oosterbosch, IR labs
On 15-jun-2007, at 0:18, Malcolm Tredinnick wrote: > > On Thu, 2007-06-14 at 16:37 +0200, Dirk van Oosterbosch, IR labs > wrote: > [...] >> >> Exactly. It runs untill I try to load a page (from another ssh >> shell). >> And I just get the prompt back: > > [...] > So maybe shove some debug pr

Re: User profile views - Does something like this make sense?

2007-06-18 Thread Gábor Farkas
zenx wrote: > I want to show the user the latest users that have seen his profile. > So everytime a logged user views another user's profile a ProfieView > object is stored in the database (or the date is updated if the user > that is viewing the profile has already viewed it before). I know this

Re: Simple Template Dict Problem

2007-06-18 Thread Aidas Bendoraitis
Hello Trey! You can iterate by the entries of a dictionary, using this: {% for i in d.items %} {{ i.0 }}: {{ i.1 }} {% endfor %} Regards, Aidas Bendoraitis aka Archatas On 6/7/07, Trey <[EMAIL PROTECTED]> wrote: > > Thanks Russ, I think my answer for today is three dimensional lists... > Ho

Re: Simple Template Dict Problem

2007-06-18 Thread Tim Terlegård
On Mon, Jun 18, 2007 at 03:44:03PM +0200, Aidas Bendoraitis wrote: > > Hello Trey! > > You can iterate by the entries of a dictionary, using this: > > {% for i in d.items %} > {{ i.0 }}: {{ i.1 }} > {% endfor %} > > Regards, > Aidas Bendoraitis aka Archatas > > > > On 6/7/07, Trey <[EMAIL

Re: Using Ajax to edit my admin page

2007-06-18 Thread Aidas Bendoraitis
Yes. If you want to use AJAX, you will need a separate view, taking manufacturer id or slug and returning 1. either the HTML with the collection select field, which should replace a default collection select field, 2 or the JSON-based collection options, which should replace the options of the col

Re: classes

2007-06-18 Thread Aidas Bendoraitis
or type() On 6/7/07, Joseph Heck <[EMAIL PROTECTED]> wrote: > > .__class__ > > On 6/7/07, Lic. José M. Rodriguez Bacallao <[EMAIL PROTECTED]> wrote: > > how can I know insede a method the type of my class dynamicaly? > > > > -- > > Lic. José M. Rodriguez Bacallao > > Cupet > > > > > > > > > --~

Providing defaults to models

2007-06-18 Thread shabda
Hi, I have a model class like this class Link(models.Model): link = models.URLField() user = models.ForeignKey(User, unique=False) text = models.TextField(maxlength = 20) votes = models.IntegerField() I want some of the fields to have defaults, like I want votes to have a defaul

Re: Providing defaults to models

2007-06-18 Thread shabda
Also this page, http://code.djangoproject.com/changeset/5202 , says that >> If you specify ``fields`` when creating a form with ``form_for_model()`` >> make sure that the fields that are *not* specified can provide default >> values, or are allowed to have a value of ``None`` So prov

Developing without tempplates

2007-06-18 Thread shabda
Hi, I am prototyping an app. Since I am just prtotyping I do not want to write templates yet. SO is there some way wherein all my variables in the view method get out put to the screen, so that I can debug them? --~--~-~--~~~---~--~~ You received this message bec

Re: Developing without tempplates

2007-06-18 Thread shabda
Also using locals() and printing is not very useful as it dumps too much data to screen to be any use. On Jun 18, 10:04 pm, shabda <[EMAIL PROTECTED]> wrote: > Hi, > > I am prototyping an app. Since I am just prtotyping I do not want to > write templates yet. SO is there some way wherein all my v

django-registration question

2007-06-18 Thread [EMAIL PROTECTED]
I'm looking at using James Bennett's django-registration app instead of what I have now (a modified version of what Jeff Croft's old Lost- Theories code, which in turn came by way of Zyons), but one thing I really like about what I have now is that no db record is created until after the activatio

RE: Providing defaults to models

2007-06-18 Thread Chris Brand
> > class Link(models.Model): > > link = models.URLField() > > user = models.ForeignKey(User, unique=False) > > text = models.TextField(maxlength = 20) > > votes = models.IntegerField() > > > > I want some of the fields to have defaults, like I want votes to have > > a default valu

Total noob needs some help installing

2007-06-18 Thread walterbyrd
I am running debian 4.x testing at home. I also have dreamhost. My plan is to try to get something working on my home box, then I'll try to install django on dreamhost. My plan is to keep the installations as similar as possible - I think that might make it easier. My home box: I have python 2.3

Re: classes

2007-06-18 Thread Joseph Heck
x = '123' x.__class__ will give a reasonable answer, x.type() doesn't. (Python 2.4) If you can get away with using type(), it's probably a lot cleaner to use... -joe On 6/18/07, Aidas Bendoraitis <[EMAIL PROTECTED]> wrote: > > or type() > > On 6/7/07, Joseph Heck <[EMAIL PROTECTED]> wrote: > >

Earn $2000 a few times a week

2007-06-18 Thread [EMAIL PROTECTED]
Huge Profits Instantly You get paid instantly. High-demand software. Create a huge income quickly and easily. http://www.tellmemoresite.com --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django users" group. To p

Re: Developing without tempplates

2007-06-18 Thread Vincent Foley
There's more than one way to do it (with apologies if you don't like Perl). One thing I like to use is IPython which allows you to start a Python interpreter from any point in your code with the entire context. So to test a function, you could add the following lines at the bottom of the function

Re: Total noob needs some help installing

2007-06-18 Thread [EMAIL PROTECTED]
> >>> django-admin.py startproject mysite Are you putting that in the python interactive shell? If so, that would seem to be your problem. You'd probably want to do "python django-admin.py startproject mysite" from the normal terminal prompt. On Jun 18, 1:33 pm, walterbyrd <[EMAIL PROTECTED]> wr

Re: delete obsolete content type entries...

2007-06-18 Thread Gabriel Farrell
On May 7, 4:32 am, Jens Diemer <[EMAIL PROTECTED]> wrote: > That surprises me. Does nobody have the same problems? > Still nobody delete a model class? > > How to clean up the django tables? With phpMyAdmin? > I've just run into a similar issue when I removed an app from a project. After some at

Q Objects: Can you do this?

2007-06-18 Thread johnny
Can you do this? citylist = CityList.objects.get( Q(city="%s" % (line[3])), Q(state=slist.id) ) I am getting the following error: citylist = CityList.objects.g

Re: Q Objects: Can you do this?

2007-06-18 Thread Jeremy Dunck
On 6/18/07, johnny <[EMAIL PROTECTED]> wrote: > I am getting the following error: > > citylist = CityList.objects.get( > NameError: name 'Q' is not defined from django.db.models.query import Q --~--~-~--~~~---~--~~ You received this message because you are sub

Re: cannot import name User (from django.contrib.auth.models)

2007-06-18 Thread RajeshD
> I was making an application that included user profiles, and I thought > I was done with the first part so I entered an sql command and got > this: > > Ian-Smiths-Computer:~/Sites/matches ismith$ python manage.py sql nest > matches.cafe: cannot import name User Notice that the error is in 'mat

Django Job: Naples Daily News

2007-06-18 Thread Stephan Schonberg
Hi folks, I just wanted to mention that the Naples Daily News in Naples, Florida has an immediate opening for a full-time Django developer. If you're a web programmer with Python and Django experience, and want to work in sunny Florida, we want to hear from you! Full job posting and details are

Re: newforms, manytomany, default value.

2007-06-18 Thread Yishai
Not much more than a noob myself - I hope the following will be useful: 1. form_from_model (and form_from_instance) are merely shortcuts - allowing you to build a form that has all the fields from the target model. In most real-life cases, you only need some of the fields, and as mentioned you ar

Re: Total noob needs some help installing

2007-06-18 Thread walterbyrd
On Jun 18, 12:14 pm, "[EMAIL PROTECTED]" <[EMAIL PROTECTED]> wrote: > > >>> django-admin.py startproject mysite > > Are you putting that in the python interactive shell? If so, that > would seem to be your problem. You'd probably want to do "python > django-admin.py startproject mysite" from the

post a job

2007-06-18 Thread Neubauer, Marissa
Hi - how can I post a job under the pages section of the group? Thanks, Marissa Marissa Neubauer Senior Recruiter | Travelocity | 682-605-4612 3150 Sabre Drive | Southlake, TX | 76092 www.travelocity.com | You'll Never Roam Alone! --~--~-~--~~~---~--~~ You receiv

Re: The going rate for Django-based web developers ...

2007-06-18 Thread Nic James Ferrier
ZebZiggle <[EMAIL PROTECTED]> writes: > Strong python, javascript, CSS, postgres, jquery (or alike), debugging > and lots of general experience in software development. And when I say > CSS, I don't mean graphic design skills, but knowing how to take a > graphic design and translate it into CSS.

Re: Problems with running Django on a remote machine

2007-06-18 Thread Malcolm Tredinnick
On Mon, 2007-06-18 at 15:04 +0200, Dirk van Oosterbosch, IR labs wrote: > > On 15-jun-2007, at 0:18, Malcolm Tredinnick wrote: > > > > > On Thu, 2007-06-14 at 16:37 +0200, Dirk van Oosterbosch, IR labs > > wrote: > > [...] > >> > >> Exactly. It runs untill I try to load a page (from another ss

SelectDateWiget Problem

2007-06-18 Thread Bryan Veloso
birthday= forms.DateField(widget=SelectDateWidget(years=range(today.year, 1900,-1)), required=False) I have this in my forms.py, and it defaults to January 1, 2007. So, I set my birthday, save, come back and it's back to that default, so if I were to save the form without changing that va

Re: User profile views - Does something like this make sense?

2007-06-18 Thread zenx
Thank you Gábor! I will make "clear_old" a static method. thanks!!! On 18 jun, 15:27, Gábor Farkas <[EMAIL PROTECTED]> wrote: > zenx wrote: > > I want to show the user the latest users that have seen his profile. > > So everytime a logged user views another user's profile a ProfieView > > obj

Re: SelectDateWiget Problem

2007-06-18 Thread [EMAIL PROTECTED]
When you edit the object, do the other fields get populated correctly? Maybe you should paste your view and your form code? On Jun 18, 7:10 pm, Bryan Veloso <[EMAIL PROTECTED]> wrote: > birthday= > forms.DateField(widget=SelectDateWidget(years=range(today.year, > 1900,-1)), required=False

FastCGI Shared host

2007-06-18 Thread rtconner
I followed the instruction at the bottom of this page: http://www.djangoproject.com/documentation/fastcgi/ I can't seem to get this running on a shared host. I've also try using the WSGIHander against jonpy, but I can't get that to work either. Any helps? ~/www/django> python mysite.fcgi WSGISe

Re: FastCGI Shared host

2007-06-18 Thread Malcolm Tredinnick
On Tue, 2007-06-19 at 01:54 +, rtconner wrote: > I followed the instruction at the bottom of this page: > http://www.djangoproject.com/documentation/fastcgi/ > I can't seem to get this running on a shared host. I've also try using > the WSGIHander against jonpy, but I can't get that to work ei

Re: CheckboxSelectMultiple error: Select a valid choice. That choice is not one of the available choices.

2007-06-18 Thread Gabriel Farrell
On Jun 15, 3:13 pm, Gabriel Farrell <[EMAIL PROTECTED]> wrote: > I've just replaced the RadioSelect widget with CheckboxSelectMultiple > for one field in my view. Here's the relevant code: > > self.fields['patron_type'] = forms.ChoiceField(choices=( > (pt.id, pt.name) for

Re: FastCGI Shared host

2007-06-18 Thread SmileyChris
On Jun 19, 2:07 pm, Malcolm Tredinnick <[EMAIL PROTECTED]> wrote: > On Tue, 2007-06-19 at 01:54 +, rtconner wrote: > > I followed the instruction at the bottom of this page: > >http://www.djangoproject.com/documentation/fastcgi/ > > I can't seem to get this running on a shared host. I've als

Re: FastCGI Shared host

2007-06-18 Thread rtconner
Python 2.4.3 ~/www/django> uname -a Linux 2.6.9-55.ELsmp #1 SMP Wed May 2 14:28:44 EDT 2007 i686 i686 i386 GNU/Linux It's a shared server. I can't control the python binary. I guess I could install virutal python, but that would be a pain, plus I think that only is python 2.4 also. On Jun 18,

Re: SelectDateWiget Problem

2007-06-18 Thread Bryan Veloso
Yep, the other fields are populated correctly. My Form: class ProfileForm(forms.Form): name= forms.CharField(required=False) avatar = forms.Field(widget=forms.FileInput, required=False) photo = forms.Field(widget=forms.FileInput, required=False) city

Re: FastCGI Shared host

2007-06-18 Thread rtconner
Dude was right, I turned APPEND_SLASH off it spit HTML out. Now it won't render in the browser. Freeking .htaccess problems I wager. On Jun 18, 8:19 pm, SmileyChris <[EMAIL PROTECTED]> wrote: > On Jun 19, 2:07 pm, Malcolm Tredinnick <[EMAIL PROTECTED]> > wrote: > > > On Tue, 2007-06-19 at 01:54 +

recommendations for hosts

2007-06-18 Thread shabda
Hi, What host do you people recommend for hosting a small-medium traffic django site. Its just a hobby hobby site so I dont want too costly a host, but since this is the first django app I would be hosting, I would prefer a host with reasonable support and one which specialises in django. --~--

django book chpt. 3 bug?

2007-06-18 Thread walterbyrd
I believe this is a bug, and I think it's been reported. I think it was also reported as fixed, but I don't think it is fixed. When I try to run the example program, I get a page full of errors, with this heading: --- AttributeError at /now/ 'function' object has no attribute 'rindex' Request Me

Re: django book chpt. 3 bug?

2007-06-18 Thread walterbyrd
Googling around some more, I managed to get it to work. But, I still don't think it's right. According to this site: http://notkeepingitreal.com/articles/category/django According to the blog on that site, parameter in urls.py needs to be changed from: (r'^now/$', current_datetime), To: (r'^n

Re: django book chpt. 3 bug?

2007-06-18 Thread Jeremy Dunck
On 6/18/07, walterbyrd <[EMAIL PROTECTED]> wrote: > ... > AttributeError at /now/ > 'function' object has no attribute 'rindex' I think you're using an old version of Django. The latest stable is 0.96. Please update to that. --~--~-~--~~~---~--~~ You received th

Re: django book chpt. 3 bug?

2007-06-18 Thread Jeremy Dunck
On 6/18/07, walterbyrd <[EMAIL PROTECTED]> wrote: ... > (r'^now/$', 'survey.views.current_datetime'), That's only necessary due to the old Django version. > I tried that, and it still didn't work. Then I changed the parameter > to: > > (r'^now/$', 'views.current_datetime'), This is due to your

html validator middleware

2007-06-18 Thread Brian St. Pierre
I recently hacked together a small middleware that validates all outgoing html and if it encounters a validation error, throws a 500 status code and error page with the validation error message(s) and html source. Similar in aim to Luke Plant's Validator App (http://lukeplant.me.uk/ resources/dja

Re: FastCGI Shared host

2007-06-18 Thread rtconner
On second though.. nope, I still get a ton of errors... WSGIServer: missing FastCGI param REQUEST_METHOD required by WSGI! WSGIServer: missing FastCGI param SERVER_NAME required by WSGI! WSGIServer: missing FastCGI param SERVER_PORT required by WSGI! WSGIServer: missing FastCGI param SERVER_PROTO

Questions on learning curve

2007-06-18 Thread [EMAIL PROTECTED]
Hello everyone, A few days ago I got an idea to build an online turnbased game (like thecrims.com) for example. I am pretty much a novice when it comes to PHP so I started to look at Ruby on rails to maybe make my development easier and faster. Stopped with Rails and found Django. Now, maybe a s

Mysql sleeping queries

2007-06-18 Thread David Reynolds
Morning, We are experiencing a problem with Mysql with django. Since an svn up yesterday (which seems to be revision 5492) we have lots of sleeping (hanging) mysql processes and we keep hitting our limit of processes (which we weren't doing before). Anyone have any idea why it may be doi

Re: recommendations for hosts

2007-06-18 Thread Gábor Farkas
shabda wrote: > Hi, > > What host do you people recommend for hosting a small-medium traffic > django site. Its just a hobby hobby site so I dont want too costly a > host, but since this is the first django app I would be hosting, I > would prefer a host with reasonable support and one which spec

Re: Mysql sleeping queries

2007-06-18 Thread Gábor Farkas
David Reynolds wrote: > Morning, > > We are experiencing a problem with Mysql with django. Since an svn up > yesterday (which seems to be revision 5492) we have lots of sleeping > (hanging) mysql processes and we keep hitting our limit of processes > (which we weren't doing before). Anyone ha

Re: Mysql sleeping queries

2007-06-18 Thread David Reynolds
On 19 Jun 2007, at 6:56 am, Gábor Farkas wrote: hi, i have no idea what went wrong, but to the developers it certainly would help, if you could find out exactly which revision broke the mysql behaviour. Difficult to tell since we hadn't svn up'd for a while... -- David Reynolds [EMAIL

Re: Questions on learning curve

2007-06-18 Thread Kenneth Gonsalves
On 19-Jun-07, at 11:21 AM, [EMAIL PROTECTED] wrote: > Now, maybe a stupid question but for how long does it take to really > understand Django/Python and start actually creating some code for the > game? from what i see on the IRC channel, you can pretty much start producing your game by day

Re: Questions on learning curve

2007-06-18 Thread Kelvin Nicholson
> Now, maybe a stupid question but for how long does it take to really > understand Django/Python and start actually creating some code for the > game? There are only parts of python you really need to learn to use Django, and other parts can be learned later. I read the book Beginning Python -