background preloader

The Django Book: Version 2.0 (English)

The Django Book: Version 2.0 (English)
Welcome to the online version of The Django Book, a free book about the Django Web framework for the Python programming language. A warning about this edition The community edition of The Django Book is in transition. While the book mentions Django version 1.4 in places, the vast majority of the book is for Django version 1.0, which was released over four years ago. Therefore this resource is extremely out of date and, until the book is finished being updated, we ask that, at this time, djangobook.com not be used for educational purposes. This book was originally published by Apress in 2009 and covered Django version 1.0. So, if you’d like to help out, hop on over to GitHub and send us a pull request!

http://www.djangobook.com/en/2.0/

A Non-Programmer Approach to Django Well if you have decided to install Django, by now you must be knowing Django is a Python based web framework and in today’s post I’ll run through Django installation process on Windows including dependencies (like installation of Python, database, database adapters and other important libraries that Django depends on). If you already have Python installed, then skip Python installation section. Installing Django/Python/Python modules is same in all versions of windows and hence below steps are valid for Windows XP and Windows Vista. Those who are using Windows Vista, just make sure you run all installations as Administrator ( Right click setup file and run as administrator ) Let’s begin by installing Python (If you already have a working Python installation, skip this section)

Using Django's TemplateTags I've had a number of e-mails about how I include the listing of blog tags and archives by month on the side of my website from people who have obviously built up a blog and now want further integration with their website. Well, it's ultra-simple thanks to a nifty Django feature called template tags. The concept behind template tags is simple - a quick snippet of code in your page templates calls some python code behind the scenes, which does some stuff, and returns either raw HTML code (yuck) or sets new variables in your template context, allowing you to manipulate and display them as you please (cool!) To get started, in the application directory for your blog, create a directory named templatetags and place an empty file in it, named _init.py_. Now, create a file - in this case we'll call it blogmonths.py_. We need to do a few things in this file:

Django - BitNami documentation - GeoDjango with PostGIS quick start guide How to create a new Django project? To start a project with Django, it is necessary to start the BitNami Console. If you are using a Virtual Appliance or AMI, you can run the commands below directly. You should create your new project inside Django projects folder located at: On Linux:

Chapter 3: Views and URLconfs In the previous chapter, we explained how to set up a Django project and run the Django development server. In this chapter, you’ll learn the basics of creating dynamic Web pages with Django. Your First Django-Powered Page: Hello World As our first goal, let’s create a Web page that outputs that famous example message: “Hello world.” If you were publishing a simple “Hello world” Web page without a Web framework, you’d simply type “Hello world” into a text file, call it hello.html, and upload it to a directory on a Web server somewhere. fíam » Building a website API with Django. Part 1: API functions WAPI and django-oauthsp are reaching the point when they are starting to become useful, so I decided it was time to write some articles explaining how they work and how you can use them in your sites. I'm currently using both of them in production at byNotes and I haven't run into any problems for now, but YMMV. This article talks about the principles behind WAPI and walks you trough the creation of a simple API function. Next articles in this series will explain more advanced concepts like custom serializations, user authentication against django.contrib.auth or using OAuth. Design Let's start by talking about the design ideas behind WAPI.

Top 12 Ruby on Rails Tutorials A former student asked me a few days ago how I learned Ruby on Rails. The answer was that I simply read alot of great tutorials. So in the spirit of sharing, here are the 12 tutorials that I found most useful: Rolling with Ruby on Rails – Curtis Hibbs of ONLamp.com offers his first excellent introduction to Ruby on Rails. django-gae-rpx - Project Hosting on Google Code Django RPX authentication backend that runs on Google App Engine with App Engine Patch. Inspired by django-rpx and django-newrpx but with support for Google App Engine thru App Engine Patch. You can see a live demo running at Note that the site might appear slow at first. The reason seems to be that the app engine unloads instances that haven't been used for some time.

Ruby in Twenty Minutes What if we want to say “Hello” a lot without getting our fingers all tired? We need to define a method! irb(main):010:0> def hiirb(main):011:1> puts "Hello World!"irb(main):012:1> end=> :hi The code def hi starts the definition of the method. HowToUseIt - django-oembed - Project Hosting on Google Code Of course, first you must add it to your INSTALLED_APPS: INSTALLED_APPS = ( .... 'oembed',) Then in your template, include the oembed tags Offline Web Applications You are here: Home Dive Into HTML5 Diving In What is an offline web application? At first glance, it sounds like a contradiction in terms. Web pages are things you download and render.

jespern / django-piston / wiki / Home – Bitbucket Get the latest version (0.2.3) here. NEW: Discussion group is hosted on Google Groups. A mini-framework for Django for creating RESTful APIs. DynamicModels - Django - Trac For an updated information about dynamic models in Django 1.2 and later ​checkout this guide. this works with django 0.96. There are some modification that make it hard to adjust it with django version 1.0 As of [5163], Django models can now be created dynamically at run-time, rather than being defined in a Python source file. While this may seem useless on the surface, it actually provides a powerful way to prototype a Django project, even by users who don't know a thing about Python!

djangoappengine - All Buttons Pressed Deprecation notice: This project has been dead for quite some time. Djangoappengine contains all App Engine backends for Django-nonrel, e.g. the database and email backends. In addition we provide a testapp which contains minimal settings for running Django-nonrel on App Engine. Use it as a starting point if you want to use App Engine as your database for Django-nonrel. We've also published some details in the Django on App Engine blog post.

Related: