Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Developing with Django
Search
Daniel Ryan
October 22, 2011
Technology
330
2
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
Developing with Django
A "get started" guide to Django powered websites.
Daniel Ryan
October 22, 2011
More Decks by Daniel Ryan
See All by Daniel Ryan
Human-first Web Design
dryan
11
2.7k
Yes We Did: Reelecting Obama.
dryan
1
500
5 Ways to Embrace HTML5 Today
dryan
5
250
CSS3: Possibilities, Best Practices and Pitfalls
dryan
1
140
CSS for Mobile
dryan
2
200
Other Decks in Technology
See All in Technology
AI駆動開発は個人技からチーム戦へ:組織でAIを使いこなすための実践設計
moongift
PRO
0
380
WEBフロントエンド研修【MIXI 26新卒技術研修】
mixi_engineers
PRO
2
900
侵入は突然に 〜 IoTマルウェアと悪用される家庭の機器 ~ / When Intrusion Strikes: IoT Malware and the Abuse of Home Devices
nttcom
0
480
20260801_スクフェス大阪
kgnkhkr
0
230
MCPをつなげて作る組織横断のAIエージェント基盤
tsubakimoto_s
0
520
Claude Mythos、Fable...フロンティアAIの最新動向と企業のセキュリティ対策
flatt_security
0
180
AIQAのナレッジ構築について
qatonchan
1
140
A Bag-of-Documents Model for Query Specificity
dtunkelang
0
190
Atlassian Cloudサポート業務でのAIエージェント活用事例
smt7174
0
210
Amazon Bedrock Managed Knowledge BaseDive Deep
ren8k
0
320
システム監視を 「システムを監視するだけ」で 終わらせないために
seiud
0
160
NYC Summit 2026 におけるAmazon Bedrock AgentCore のアップデート
ren8k
3
300
Featured
See All Featured
Building Flexible Design Systems
yeseniaperezcruz
330
40k
How To Stay Up To Date on Web Technology
chriscoyier
790
250k
Marketing to machines
jonoalderson
1
5.6k
CSS Pre-Processors: Stylus, Less & Sass
bermonpainter
360
30k
How to Build an AI Search Optimization Roadmap - Criteria and Steps to Take #SEOIRL
aleyda
1
2.1k
DBのスキルで生き残る技術 - AI時代におけるテーブル設計の勘所
soudai
PRO
67
56k
The Myth of the Modular Monolith - Day 2 Keynote - Rails World 2024
eileencodes
28
3.6k
Leo the Paperboy
mayatellez
8
2k
So, you think you're a good person
axbom
PRO
2
2.1k
Music & Morning Musume
bryan
47
7.3k
Chasing Engaging Ingredients in Design
codingconduct
0
250
What the history of the web can teach us about the future of AI
inesmontani
PRO
1
650
Transcript
Developing with Django Daniel Ryan http://dryan.com
Some Background Lawrence Journal-World Ellington Pycon 2005 • • •
Sites Powered by Django
Acronyms Abound MTV - Model • Template • View DRY
- Don’t Repeat Yourself ORM - Object-relational Mapping • • •
MTV vs. MVC Model = Model Template = View View
= Controller • • •
Installing Django Check out http://dryan.com/articles/snow-leopard-64bit- mamp/#python Python Trunk versus Stable
Release Third Party Libraries • • • •
A Django Workflow Create a project Configure settings.py Configure urls.py
Create the database tables • • • •
A Django Workflow Create an app Define your models Create
the database tables Define your urls Define your views • • • • •
Reduce, Reuse, Recycle direct_to_template redirect_to archive_index archive_year archive_month archive_week archive_day
archive_today object_detail (date based) object_list object_detail (list based) create_object update_object delete_object Django Generic Views
Django Templates Just like PHP, except the exact opposite True
separation of logic and presentation Global templates vs. app templates Blocks Tags • • • • •
Built-in Tags autoescape block comment cycle debug extends filter firstof
for for ... empty if ifchanged ifequal ifnotequal include load now regroup spaceless ssi templatetag url widthratio with
Built-in Filters add addslashes capfirst center cut date default default_if_none
dictsort dictsortreversed escapejs filesizeformat first fix_ampersands floatformat force_escape get_digit iriencode join last length_is linebreaks linebreaksbr linenumbers ljust lower make_list phone2numeric pluralize pprint removetags rjust safe safeseq slice slugify stringformat striptags time timesince title truncatewords truncatewords_html unordered_list upper urlencode urlize urlizetrunc wordcount wordwrap
Other Freebies Admin site Authentication Cache system Conditional content processing
Comments Content types Cross Site Request Forgery protection Databrowse E-mail (sending) Flatpages Humanize Internationalization Jython support “Local flavor” Pagination Redirects Serialization Sessions Signals Sitemaps Sites Syndication feeds (RSS/Atom) Unicode in Django Web design helpers django.contrib
Resources http://docs.djangoproject.com irc://irc.freenode.net/django http://thisweekindjango.com/ http://www.djangosnippets.org/ http://code.djangoproject.com/wiki/Tutorials • • • •
•