December 28, 2011 6:27 p.m.
I wanted to share a quick practical example of how Fabric, can make your development life easier. If you're unfamiliar with Fabric I recommend checking out its tutorial which describes Fabric thusly;
Fabric is a Python (2.5 or higher) library and command-line tool for streamlining
the use of SSH for application deployment or systems administration tasks.
The tutorial is a great resource as Fabric does not have a dense API. In fact, it has a childishly simple API. Today, I found myself using it to simplify a process I had been repeatedly performing manually. A client site of ...
Read More
Updated 12/28/11 @ 06:27PM CST by dlacewell
Categories:
Django Python
Tags:
deployment
fabric
python
2 Comments
September 21, 2011 12:37 p.m.
GeoDjango is a very powerful tool for storing and manipulating geographic data using the Django ORM. It provides a simple API to determine distances between two points on a map, find areas of polygons, locate the points within a polygon, and much more.
GeoDjango is fairly well documented on the Django website. My aim with this walkthrough is to reduce the Django documentation to a simple set of steps that will quickly get you started experimenting with GeoDjango. As a result, some of the initial steps are summarized from the Django site with only slight modifications to fit the circumstances ...
Read More
Updated 09/21/11 @ 12:37PM CDT by jjasinski
Categories:
Django Python
Tags:
django
geo
geographic
geospatial
latitude
longitude
python
August 29, 2011 9:47 a.m.
At its minimum, the Django Admin is an effective tool for viewing and manipulating data within a Django database. At its max, it can be a robust application allowing clients and administrators to better manage their web applications. This article aims to highlight some of the admin customizations that I find particularly useful when trying to make the admin more than just a data browsing tool. If you’d like to follow along with this tutorial, you may view the associated, fully-functional Django Application at github: https://github.com/imagescape/chicagodjango-demo1. The purpose of this application is simply to demonstrate ...
Read More
Updated 08/29/11 @ 09:47AM CDT by jjasinski
Categories:
Django Python
Tags:
admin
customization
django
hacks
programming
python
November 17, 2010 9:52 a.m.
Django forms are very convenient tools for Django development, but sometimes I find myself wrangling with them to get them to do what I want them to do. I’ve compiled a few simple form examples that I find useful for various form-related tasks.
Say you have a model that looks like this:
Example 1:
class MyModel(models.Model):
myfield1= models.CharField(u'Field 1 Name', help_text='Field 1 help',
max_length=20, blank=True)
myfield2 = models.CharField(u'Field 2 Name', help_text='Field 2 help',
max_length=20, blank=True)
As we know, generating a basic ModelForm for this model is ...
Read More
Updated 11/17/10 @ 09:52AM CST by jjasinski
Categories:
Django Python
Tags:
django
forms
python
October 28, 2010 3:41 p.m.
Of all the Django modules that are out there, several stand out as ones that I keep coming back to. These are some of my favorites:
1) Django Debug Toolbar - http://robhudson.github.com/django-debug-toolbar/ Django Debug Toolbar is an extremely useful Django application for debugging a site from “Django’s perspective.” It should only be used during the development of a site. This toolbar overlays an expandable menu over every page of your website. Upon expanding this menu, you can see all of the request variables and settings variables associated with that page. Also, it allows you to view ...
Read More
Updated 10/28/10 @ 03:41PM CDT by jjasinski
Categories:
Django Python
Tags:
compress
debug
django
extensions
favorite
modules
python
rosetta
south