You Are At The Django Category Archive

Django Pony Obamerized

01.20.09 // Django // (0)

Django 1.0 Template Development

01.06.09 // Django // (0)

Yes, another Django book i purchased. But this time not over Amazon, but direct from the publisher! Cheaper! Way Cheaper!

Categories & Subcategories With Django

12.11.08 // Django // (0)

class Category(models.Model):
name = models.CharField(core=True, maxlength=200)
slug = models.SlugField(prepopulate_from=(’name’,))
parent = models.ForeignKey(’self’, blank=True, null=True, related_name=’child’)
description = models.TextField(blank=True,help_text=”Optional”)
class Admin:
list_display = (’name’, ‘_parents_repr’)
def __str__(self):
p_list = self._recurse_for_parents(self)
p_list.append(self.name)
return self.get_separator().join(p_list)
def get_absolute_url(self):
if self.parent_id:
return “/tag/%s/%s/” % (self.parent.slug, self.slug)
else:
return “/tag/%s/” % (self.slug)
def _recurse_for_parents(self, cat_obj):
p_list = []
if cat_obj.parent_id:
p = cat_obj.parent
p_list.append(p.name)
more = self._recurse_for_parents(p)
p_list.extend(more)
if cat_obj == self and p_list:
p_list.reverse()
return p_list
def get_separator(self):
return ‘ :: ‘
def _parents_repr(self):
p_list = self._recurse_for_parents(self)
return self.get_separator().join(p_list)
_parents_repr.short_description = [...]

My Blog I Made With My Book

11.13.08 // Django // (0)

My Django Book Arrived!!!

11.12.08 // Django // (0)

Django IRC & Mibbit.com

11.11.08 // Django // (0)

If you would like to get some realtime Django help from the experts i recommend you have a look at the Django IRC channel. You can connect @
Django IRC Channel
Server Address: irc.freenode.net
Channel: #django
If you are new to Django i recommend that you also join #django-newbie
You can connect via a webbrowser if you couldn’t be bothered [...]

Practical Django Projects

11.10.08 // Django // (0)

Up to Chapter 5 of this book. Already i know what the deal is with views, have made a full admin panel which error checks all entries, has categories, tagging and can generate HTML! Whoa! So good. Just notice that you may need to use SVN number 7966 and tagging r133 which can be [...]

My Book!

11.07.08 // Django // (0)

Practical Django Projects

11.07.08 // Django // (0)

It was this error that spent 2 hours of my day today:
ImportError: No module named coltrane
I had included my PythonPath entry manually into my MacOSX home directory via:
vi .profile
and entering:
export PYTHONPATH=/Users/myname/mydjangodirectory:$PYTHONPATH
This indeed works, but i was using a super user account to run all of my commands because i wanted the development web server to [...]

New Book in the Mail!

11.07.08 // Django // (0)

Django and Subversion Hourly Updates

08.30.08 // Django // (0)

So if you are developing with Django and python you may be running off the Django SVN trunk. It can be a pain constantly running the update command when you simply want to be up with the development. Of course you would run this on a development server and not a production server! But i [...]

Django Wallpaper 1440 x 900

08.29.08 // Django // (0)

Django Part 2!

08.28.08 // Django //Comments Off

So i have been reading through the python and django books a bit more. The first one, Developing websites with Django was great, very project based, but it didn’t really go into the depth i needed in order to start programming my own websites. So i picked up my other book: