Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Sign up for free
Menu
Search
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Pricing
Search
Sign in
Sign up for free
Django - Framework do Tworzenia Aplikacjii Webo...
Search
Marcin Mierzejewski
February 22, 2008
Programming
81
0
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
Django - Framework do Tworzenia Aplikacjii Webowych
Prezentacja była zaprezentowana na PyCon Kraków (PyKonik)
Marcin Mierzejewski
February 22, 2008
More Decks by Marcin Mierzejewski
See All by Marcin Mierzejewski
Kup pan cegłe... Kup Pan cegłę, czyli wstęp do algorytmów rekomendacyjnych
mrmierzejewski
1
160
Python i Orange - wstep do eksploracji danych (data mining)
mrmierzejewski
1
670
Python i Django - szybkie i łatwe tworzenie aplikacji webowych
mrmierzejewski
0
580
Introduction to Django 1.0
mrmierzejewski
1
140
Other Decks in Programming
See All in Programming
不幸な GC
chencmd
0
900
20260914 AIエージェント時代のPlatform Engineering LLM基盤とプロダクトの責務境界線
kanfab1
2
620
Claude Codeを組織的に動かして月400PRを実現した話
happy_ryo
0
270
Swift愛好会100回記念 第1回を振り返る
jollyjoester
0
120
Gmail/Google DriveをトリガーにAIエージェントを動かそう! / Run AI agents with Gmail/Google Drive as triggers!
har1101
3
490
Seeing Through Serverless: Observability for AWS Lambda with ADOT and CloudWatch Application Signals
seike460
PRO
1
130
[GoCon2026] When Goroutines Are Not Enough: Runtime Locality in High-Throughput Go
takehaya
6
1.8k
AWS DevOps Agentで インシデント対応をAIに任せたい
honmarkhunt
7
2.7k
巨大モノリシックアプリ モダン化大作戦
ktcryomm
0
620
Deep dive into the select statement (GopherCon UK)
jespino
0
170
標準パッケージに uuid が追加された 背景から見る Go らしい意思決定 / go_127_uuid_decision
convto
5
6k
Security issues being discussed on Web Platforms
petamoriken
0
690
Featured
See All Featured
Design in an AI World
tapps
1
310
Sharpening the Axe: The Primacy of Toolmaking
bcantrill
46
3k
Visualization
eitanlees
152
17k
Color Theory Basics | Prateek | Gurzu
gurzu
0
460
Mind Mapping
helmedeiros
1
350
Exploring anti-patterns in Rails
aemeredith
3
500
Introduction to Domain-Driven Design and Collaborative software design
baasie
1
980
How to Align SEO within the Product Triangle To Get Buy-In & Support - #RIMC
aleyda
2
1.8k
GraphQLの誤解/rethinking-graphql
sonatard
75
12k
SEOcharity - Dark patterns in SEO and UX: How to avoid them and build a more ethical web
sarafernandez
0
270
Groundhog Day: Seeking Process in Gaming for Health
codingconduct
0
340
WCS-LA-2024
lcolladotor
0
820
Transcript
Marcin Mierzejewski www.mierzejewski.net
Django Framework do tworzenia aplikacji webowych
Historia 2003 - Kansas, USA 2005 - licencja BSD 2005
- wersja 0.90 2006 - wersja 0.95 2007 - wersja 0.96.1
Cechy Użytkownicy Uwierzytelnianie Formularze Admin Panel Middleware
MTV Model Template View Model - dane Template - prezentacja
View - logika
Model SQL Free ORM API
Template restrykcyjne i dziedziczenie {{ zmienne }}, {% tagi %},
filtry HTML, CSS, CSV, XML, ...
URL /news.php?id=5756 /2008/02/12/drugie-spotkanie-pykonika
Blog Lista Szczegóły Panel administracyjny Użytkownicy
Projekt # django-admin.py startproject strona strona/ __init__.py manage.py settings.py urls.py
Panel # ./manage.py syncdb # ./manage.py runserver
Aplikacja # ./manage.py startapp blog blog/ __init__.py models.py views.py
Model class Blog(models.Model): tytul = models.CharField(maxlength=250) slug = models.SlugField() tresc
= models.TextField() data = models.DateTimeField() class Admin: pass
Panel # ./manage.py syncdb # ./magage.py runserver
URL urlpatterns = patterns('', (r'^$', 'strona.blog.views.lista'), (r'^(?P<s>[A-Za-z-]+)/$', 'strona.blog.views.detale'), )
View def lista(request): blogi = Blog.objects.all() return render_to_response('lista.html', { 'blogi':
blogi }) def detale(request, s): blog = get_object_or_404(Blog, slug = s ) return render_to_response('detale.html', { 'blog': blog })
Template lista.html <h1>Blog</h1> {% for blog in blogi %} <h2>{{
blog.tytul }}</h2> <h3>{{ blog.data }}</h3> <a href='/blog/{{ blog.slug }}'>Więcej</a><br> {% endfor %}
Template detale.html <h1>{{ blog.tytul }}</h1> <h2>{{ blog.data }}</h2> {{ blog.tresc
}}
Rachunek http://127.0.0.1:8000/ /drugie-spotkanie-pykonika/
Społeczność DjangoProject.com DjangoPeople.net DjangoSnipplets.com DjangoGigs.com