Re: The best hoster to install Django

2009-06-07 Thread K.Berkhout
I forgot the "etc". :-) On 7 jun, 11:38, Kenneth Gonsalves <law...@thenilgiris.com> wrote: > On Sunday 07 June 2009 14:53:17 K.Berkhout wrote: > > > Depends on what your location and the location of your (future) users > > is. > > Are you based in E

Re: The best hoster to install Django

2009-06-07 Thread K.Berkhout
Depends on what your location and the location of your (future) users is. Are you based in Europe or the USA? Kevin On 7 jun, 09:47, Bro wrote: > Thanks a lot to Kenneth Gonsalves and Dj Gilcrease :) > > Regards > Bro > > On 7 juin, 02:20, Kenneth Gonsalves

Django SVN vs. stable

2009-06-06 Thread K.Berkhout
Hi, I'm about to start a new project using Django. Do you recommend me to start with the stable release and convert to 1.1 later, or would it be better to start with the development SVN version? Thanks, Kevin --~--~-~--~~~---~--~~ You received this message

Re: request.session in template tag?

2009-06-01 Thread K.Berkhout
Looks like something similar to the problem I had, see http://groups.google.nl/group/django-users/browse_thread/thread/cf3e243d3bc5ca3b?hl=nl Kevin On 1 jun, 19:53, "bax...@gretschpages.com" wrote: > I'm trying to write a template tag that accesses the user's >

Re: user.is_authenticated

2009-06-01 Thread K.Berkhout
ll the variables from the default contexts plus > the ones you include in the dictionary... the auth context is loaded by > default (if i remember correctly)... > > hope it helps, > > g > > 2009/6/1 K.Berkhout <ke...@berkhout.us> > > > > > > &g

user.is_authenticated

2009-06-01 Thread K.Berkhout
Hi, Is there a way I can access the "user.is_authenticated" method in every view, without having to manually pass the User model to every template? Basicly I want to show a login or logout link on every page, depending on wether the visitor is logged in or not. I've included the following if

Re: Migrating (importing) SQL dump for one model

2009-06-01 Thread K.Berkhout
I think a database migration tool is what you're looking for. I've no experience with such tools, but you could look on http://code.djangoproject.com/wiki/SchemaEvolution for database migration tools currently available. Kevin On 1 jun, 10:09, Bastien wrote: > Hi, >

Re: Comparing timestamps

2009-05-31 Thread K.Berkhout
Already got it, it's: timedelta(seconds=1) In stead of: datetime.timedelta(seconds=1) On 31 mei, 14:29, "K.Berkhout" <ke...@berkhout.us> wrote: > Hmm, seems like the method always returns false, anybody knows what > goes wrong? > > On 31 mei, 12:29, "K.Be

Re: Comparing timestamps

2009-05-31 Thread K.Berkhout
Hmm, seems like the method always returns false, anybody knows what goes wrong? On 31 mei, 12:29, "K.Berkhout" <ke...@berkhout.us> wrote: > Thanks you very much for the solution, Damien! > > On 30 mei, 22:11, Damien GOMBAULT <desint...@gmail.com> wrote: > >

Re: Comparing timestamps

2009-05-31 Thread K.Berkhout
Thanks you very much for the solution, Damien! On 30 mei, 22:11, Damien GOMBAULT wrote: > Write a method is_modified in your Post model. > You can use datetime.timedelta to compare dates. > > def is_modified(self): >    second = datetime.timedelta(seconds=1) >    delta =

Comparing timestamps

2009-05-30 Thread K.Berkhout
Hi, Let's say I have the following post model: class Post(models.Model): text = models.TextField() created = models.DateTimeField(auto_now=False, auto_now_add=True) last_modified = models.DateTimeField(auto_now=True, auto_now_add=False) I want to display the