Re: Has anything changed with Sagepay/protx apart from the name?

2009-07-14 Thread Kip Parker
No, I did not. Oh dear. Thanks for pointing this out Karen. I am now off to the Satchmo group to post the same message, in case anyone was wondering what it was all about. Kip. On Jul 14, 1:47 pm, Karen Tracey <kmtra...@gmail.com> wrote: > On Tue, Jul 14, 2009 at 7:42 AM, Kip

Has anything changed with Sagepay/protx apart from the name?

2009-07-14 Thread Kip Parker
I noticed whilst researching which payment gateway to use that Protx has become Sagepay. Anyone know if they've just changed the name (so that the Protx payment module still works OK) or if they've changed the product at all (so the Protx module doesn't)? Kip.

Re: LDAP support in Django?

2009-06-05 Thread Kip Parker
There's a lot of useful stuff on djangosnippets for LDAP and Active Directory too: http://www.google.co.uk/search?q=+LDAP+site%3Ahttp%3A%2F%2Fwww.djangosnippets.org On Jun 5, 6:17 pm, Adam Stein wrote: > Just google django and ldap.  That's how I found how to set up

Re: FileField uploading into an user-specific path

2009-04-29 Thread Kip Parker
upload_to can be a callable - http://docs.djangoproject.com/en/dev/ref/models/fields/#filefield. On Apr 29, 4:59 am, "Carlos A. Carnero Delgado" wrote: > Oops, too quick to press reply :o > > On Tue, Apr 28, 2009 at 11:53 PM, Carlos A. Carnero Delgado > >

Re: Change the url

2009-01-08 Thread Kip Parker
You can use reverse() in your get_absolute_url method, it works the same as the url template tag in using your url patterns to generate the url. http://docs.djangoproject.com/en/dev/topics/http/urls/?from=olddocs#reverse On Jan 8, 12:58 pm, Praveen wrote: > Hi

Re: Frustration with custom Inline forms

2008-11-17 Thread Kip Parker
There's a problem with the exclude statements above, you've got tuple- trouble, missing trailing commas: exclude = ('a55_id') should be ('a55_id',) or ['a55_id'] easy mistake, search for "tuple" in this group and you'll see you have company. Kip. On Nov 17, 2:01 pm, Ben Gerdemann <[EMAIL

Re: admin site problem

2008-11-17 Thread Kip Parker
You need to turn it into a string, this will do it: def __unicode(self): return '%s' % self.integer_column On Nov 17, 12:41 pm, Vicky <[EMAIL PROTECTED]> wrote: > I found the problem.. I used : > >                             def __unicode__(self): > > function in my model. so it a can

Re: Uploaded Files -> Don't appear in folder, but no errors

2008-10-27 Thread Kip Parker
To get a new object from a ModelForm you just save it, so the view should be something like: def uploadImage(request): if request.method == 'POST': #if submitted form = UploadNewImageForm(request.POST, request.FILES) if form.is_valid(): ir = form.save() rw =

Re: Django Model design: OOP or Database-centric approach?

2008-10-23 Thread Kip Parker
Neither seem right to me. I'm not quite sure what the application does, but it seems likely that a person only belongs to one family, in which case you'll need a foreign key like this. class Adult(models.Model): name = models.CharField(maxlength=30) partner =

Re: Using mod_python with Lighttpd - advice on the best set up

2008-09-30 Thread Kip Parker
Sounds good, how did you get it to do that? On Sep 30, 1:03 pm, Erik Allik <[EMAIL PROTECTED]> wrote: > Apache can also start/restart your FastCGI process(es) as needed. > > Erik > --~--~-~--~~~---~--~~ You received this message because you are subscribed to the

Re: Using mod_python with Lighttpd - advice on the best set up

2008-09-30 Thread Kip Parker
alled "reverse proxying" > where requests for static media are handled up-front > by a lightweight server and all other requests are sent through > to apache / mod_whatever for the heavy lifting. > > On Sep 29, 1:37 pm, Kip Parker <[EMAIL PROTECTED]> wrote: > > >

Re: image path in CSS - won't work???

2008-09-30 Thread Kip Parker
A good start is to check you can view http://yoursite.com/site_media/img/menu.jpg directly, if you get an error it will probably point you in the right direction. On Sep 30, 10:13 am, Bobo <[EMAIL PROTECTED]> wrote: > Hi everyone, > > I'm having a very strange problem with my Django project.

Re: Using mod_python with Lighttpd - advice on the best set up

2008-09-29 Thread Kip Parker
Thanks Frank, that's very interesting. A lack of complaining users is much to be desired. Have you ever used this set up for multiple sites? I have about 20 sites running, and there may well be more in the future. It would be excellent also to know what you found painful about mod_python. All

Using mod_python with Lighttpd - advice on the best set up

2008-09-29 Thread Kip Parker
Having had a few problems with memory usage on my Django sites, I've realised a problem with my current set up is that apache is serving media files as well as doing all the mod_python django stuff. The recommended solution I keep coming across is to serve media files from a separate lightweight

Re: Absolute URL vs Relative URL, or ~ ?

2008-09-16 Thread Kip Parker
On Sep 16, 5:42 pm, Dana <[EMAIL PROTECTED]> wrote: > Kip, don't you mean {{ model.get_image_url }}? > get_FOO_url() has gone in Django 1.0. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django users" group. To

Re: Absolute URL vs Relative URL, or ~ ?

2008-09-16 Thread Kip Parker
wildcard * in site framework?) > > I will looking into TEMPLATE_CONTEXT_PROCESSORS thought, maybe a > customized filter would help > > :-) > > On Sep 16, 8:01 pm, Kip Parker <[EMAIL PROTECTED]> wrote: > > > > no, it's not THAT simple. > > > It really is that simpl

Re: Absolute URL vs Relative URL, or ~ ?

2008-09-16 Thread Kip Parker
> no, it's not THAT simple. It really is that simple, honest, but your brain has made it all complicated. Look at http://docs.djangoproject.com/en/dev/ref/contrib/sites/ (sites framework), TEMPLATE_CONTEXT_PROCESSORS setting and RequestContext and the URL dispatcher docs, the answers to your

Re: polymorphism and abstract classes

2008-08-21 Thread Kip Parker
m guessing, leave me with the same > problem as before because I set it asabstract(and the same other > problem of unflattened table hierarchy if I didn't set it asabstract).  Is it > possible to specify this in the model? > > If these are elementary questions, my apologies, I'm

Re: polymorphism and abstract classes

2008-08-20 Thread Kip Parker
Maybe have a look at generic relations? http://www.djangoproject.com/documentation/models/generic_relations/ You could also use multi-table inheritance rather than abstract classes, then use the parent class Animal as the key in ZooEnclosure. Abstract classes can't exist on their own, which I

Re: IE6/Safari not keeping cookie after closing browser

2008-05-01 Thread Kip Parker
Absolutely, cookies are subject to user settings and behaviour so unreliable, but as far as default browser behaviour goes I think IE6 keeps cookies forever, Firefox has an expiration limit of 90 days, and my Safari 3 at least has cookies listed to expire in 2099. So it ought to work if it's

Re: Looping....

2008-04-18 Thread Kip Parker
I needed something like this to repeat a part of the template x times, but I couldn't get this to work, the filter repeatedly returned the range(0,10) so gave a recursion depth error. I may have set it up wrong. I ended up making a repeat tag: def do_repeat(parser, token): try:

Re: edit_inline and models with FileField(core=True)

2008-04-03 Thread Kip Parker
Thanks, that's the one! I'm a bit wary of using the branches for production sites, do you have any experience of using the newforms- admin branch? On Apr 3, 1:51 pm, "Karen Tracey" <[EMAIL PROTECTED]> wrote: > On Wed, Apr 2, 2008 at 3:18 PM, Kip Parker <[EMAIL PROTECTED]>

edit_inline and models with FileField(core=True)

2008-04-02 Thread Kip Parker
This model is edited inline with the ImageField being the only one with core=True. class Image(models.Model): image = models.ImageField(upload_to="images", core=True) caption = models.CharField(blank=True, max_length=250) artist = models.ForeignKey(Artist,