Tag programming

How I Moved My Commercial Projects to Newforms-Admin

Django 1.0 Alpha is out, and with it come some major API changes to Django's internals. This means you need to make a number of changes to your Django projects before upgrading Django to a recent copy. I've got a handful of commercial and public-facing websites running on Django, so I decided now is a good time to upgrade them.

Jutda: Django-powered Solution Provider

In my previous post I mentioned Jutda, a Django-powered company that I'm working on in my spare time. I would now like to formally introduce Jutda to the Django community and outline a few exciting projects that are on their way. World, meet Jutda!w

Overdue Catchup

A quick update on a few projects including DjangoSites, WhisperGifts, Jutda, a Django-powered Forum package, and my OpenID implementation.

Django Menuing System

Although Django's template system is very easy to get the hang of, it's not for everybody. In particular, it's not for people whose job it is to publish content without having any technical know-how. For this reason, I'm giving away a simple menuing application for Django that lets your content editors addand change menu items without bothering your template authors.

DjangoPoweredSites Grows Up

I've spent some significant time over the past weekend moving website listings from the old DjangoPoweredSites wiki page to DjangoSites. That brings the total number of Django-driven websites listed to over 800! We'll now close down the wiki page as it has become redundant, but require a little bit of help cleansing the new list.

Easy Multi-Part E-Mails with Django

Django provides an easy way to send multi-part text/HTML messages. I've recently built on top of this existing framework to provide an ultra-easy way to send templated HTML and plain-text messages with minimal code duplication.

Django: Multiple Aliases for a Single Website

In these days of cheap domains, it's often desirable to own multiple domains for a single website. You've probably got each of the .com, .net and .org domain names, along with a country-specific domain. You want each of these to present exactly the same website to the world, but good design says that each web page should have one, and exactly one, URL. So what's the best way to serve this up without having an Apache config for each domain?

Mixing OpenID into Django's authentication system

OpenID is a de-centralised authentication system that is making a splash in a big way. In this post I give an overview of what OpenID is, and how I'm going about integrating it with Django's user-management / authentication system.

Validating a Username via jQuery with Ajax

The phrase 'simplifying the user experience' (or it's cousins) is thrown around regularly these days, without many examples on HOW to actually make life easier for the end user. In my opinion it's about removing needless junk wherever possible, letting the user focus on what's actually important. A simple example I've extracted from a current project is minimising needless page loads. Read on to find out how I validate availability of a username during the Django registration process.

DjangoSites: We Want YOU!

We're at 260 sites listed on DjangoSites. The DjangoPoweredSites page has 3-4 times that number - so if you've got a website built with Django, why not submit it (for free, no less) and show it off to the world?

Djangosites Updates

Djangosites.org was launched last week as a new way to show off the many websites that are built with Django but that don't get much fanfare within the community as they aren't technology based. I've received some fantastic feedback from the community so have improved the RSS feeds and access to info about source-code.

Introducing Djangosites.org

Over the past few weeks I've been working on a website to allow the Django community to showcase what's out there that's built using the fantastic Django framework. With input from others in the community, the site is now live. I introduce to you, DjangoSites.org

Using The WebThumb API with Python

There is a fantastic free service available to create screenshots of websites using an API at bluga.net. The problem is, there are no samples in Python. As part of a project I'm working on with the Django community, I've written a simple Python interface to the bluga.net webthumb API which lets you pass in a URL and receive back a screenshot.

Using Subdomains with Django

Sometimes it's really handy to give users their own sub-domain, especially when they're uploading their own content to your Django application. I've done this for a few private projects so far, and it's really quite an easy way to give people an extra level of customisation in your application - it also allows you to make even more beautiful URL's that you might otherwise be doing.

Helping Sort Django's Error Emails

Running multiple Django sites, all with debugging disabled? Getting confused as to which traceback emails belong to which site? This simple Django tip shows how to alter the e-mails being sent by Django so you can more easily work with these e-mails which are a very useful site management tool.

Blog Spam Protection

I've made a small change to my blog to try and slow down the spammers a bit - the first step in a few that I have planned.

Simple Javascript Spell Checking

In a project I've been working on lately, it's been an important requirement to allow users to spell-check the text they're entering, as it's going to be seen by their family and friends. I spent a bit of time looking at different spell-checking options, which ranged from simple checkers to what seemed to be complete working realtime MS Word™-style spell checkers with underlining and right-click support. In the interests of keeping everything simple to use and as cross-browser as possible, I've settled on a simple yet elegant solution.

The Pareto principle (Or, why the 80/20 rule always bites us in the ass)

There is a common saying that 80% of a project takes 20% of the time and budget - and the remaining 20% of the work takes 80% of the time. This is no more correct than in the software development environment. Warning: Rant ahead!

ChangeManipulators on only part of a model

There is a cool function in Django for managing forms, and automatically doing data validation and manipulation before updating the database. That same cool function also has a critical issue in it that makes it impossible to reliably only update part of a model - except that critical issue has a critical fix that has been around for almost a year now and has never been documented.

Housekeeping

I've done some minor changes to the website recently to make life easier - including a new website template.

Sending E-Mails via Templates

Django's templates are fantastic for displaying content on your website, but what if you could use the power of the template system in other areas, such as e-mails sent from your application for registration or update purposes? Well, you can do just that - read on for an example.

Using Django's TemplateTags

Often times on a website you will want to include the same block of dynamic data in your template, regardless of the view that generated the page. Common examples are lists of tags or categories, navigation bars (built from the database) and other such lists - such as those on the right side of this page. The good news is that you don't have to modify every single view to add these details to the template context. The better news is that it's fantasmically powerful with Django.

A Django Blog: Redux

A recent upgrade to Django has made some drastic and far-reaching changes, called 'Magic Removal'. As such, all earlier code that relies on Django has to be updated - including my blog tutorials. Read on for a summary of the changes you'll have to make.

XSS Vulnerability

Simon Greenhill, a New Zealand based programmer, has alerted me to a cross-site scripting (XSS) vulnerability in the comments portion of my blog - that seems to extend to the comments module in ALL django applications.

Django: Magic-Removal Upgrade

I've updated my websites to run on the latest Django code base, named 'magic removal'. The updated blog code is coming soon, as it has to be altered in many ways to make it work on the new code. This should be the last major base change to Django before their 1.0 release.

Building A Blog with Django #3

The third portion of my series on building a weblog application with Django: learn how to add the global Django comments module to your application, and list all posts for a given tag.

Building a Blog with Django #2

The second part of my 'Building A Blog with Django' series, showing how to actually make your database visible to the world - you'll be putting your weblog online for all to see. See part 1 for information on creating the database.

Django: My First Impressions

I've always been a PHP coder - everything web-based that I wrote was in PHP. Until last week. I've discovered Django, and I'm wishing I found it earlier. And why haven't I been using Python until now? Read on for my first impressions of the Django web framework.