$30 off During Our Annual Pro Sale. View Details »
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Django Nedir, Yenir mi?
Search
Cihan Okyay
April 03, 2013
Programming
0
160
Django Nedir, Yenir mi?
Django'ya Giriş sunumu. Sunum 2011 Özgür Web Günleri sırasında yapıldı.
Cihan Okyay
April 03, 2013
Tweet
Share
More Decks by Cihan Okyay
See All by Cihan Okyay
Docker 101
cihann
3
420
Daha İyi Geliştirme Ortamları İçin Vagrant
cihann
2
130
Özgür Yazılım Geliştirerek Sosyalleşmek
cihann
0
110
Nasıl Çalışıyorum?
cihann
1
120
Other Decks in Programming
See All in Programming
ハイパーメディア駆動アプリケーションとIslandアーキテクチャ: htmxによるWebアプリケーション開発と動的UIの局所的適用
nowaki28
0
390
Tinkerbellから学ぶ、Podで DHCPをリッスンする手法
tomokon
0
120
FluorTracer / RayTracingCamp11
kugimasa
0
220
なあ兄弟、 余白の意味を考えてから UI実装してくれ!
ktcryomm
11
11k
LLM Çağında Backend Olmak: 10 Milyon Prompt'u Milisaniyede Sorgulamak
selcukusta
0
110
WebRTC と Rust と8K 60fps
tnoho
2
1.9k
俺流レスポンシブコーディング 2025
tak_dcxi
14
8.5k
大体よく分かるscala.collection.immutable.HashMap ~ Compressed Hash-Array Mapped Prefix-tree (CHAMP) ~
matsu_chara
1
210
251126 TestState APIってなんだっけ?Step Functionsテストどう変わる?
east_takumi
0
310
안드로이드 9년차 개발자, 프론트엔드 주니어로 커리어 리셋하기
maryang
1
110
LLMで複雑な検索条件アセットから脱却する!! 生成的検索インタフェースの設計論
po3rin
2
650
Level up your Gemini CLI - D&D Style!
palladius
1
180
Featured
See All Featured
Put a Button on it: Removing Barriers to Going Fast.
kastner
60
4.1k
Exploring the Power of Turbo Streams & Action Cable | RailsConf2023
kevinliebholz
36
6.2k
The Pragmatic Product Professional
lauravandoore
37
7.1k
Designing Dashboards & Data Visualisations in Web Apps
destraynor
231
54k
A Tale of Four Properties
chriscoyier
162
23k
Large-scale JavaScript Application Architecture
addyosmani
515
110k
Fantastic passwords and where to find them - at NoRuKo
philnash
52
3.5k
BBQ
matthewcrist
89
9.9k
Into the Great Unknown - MozCon
thekraken
40
2.2k
Automating Front-end Workflow
addyosmani
1371
200k
Thoughts on Productivity
jonyablonski
73
5k
Context Engineering - Making Every Token Count
addyosmani
9
490
Transcript
nedir, yenir mi? Cihan Okyay
[email protected]
@cihann
* Open source * Nesne Yönelimli * Temiz sözdizimi *
Öğrenmesi kolay * Güçlü
Guido van Rossum
a = 10 if a > 5: print 'büyük' else:
print 'küçük' def factorial(x): if x == 0: return 1 else: return x * factorial(x - 1) factorial(5)
Django The Web framework for perfectionists with deadlines ...
... not a framework for beginners with deadlines
Tarihi 2003: Kansas, USA 2005: BSD & 0.90 2008: 1.0
2011: 1.3
Özellikler * Dökümantasyon * ORM * URL dispatcher * Templates
* Interactive terminal * Admin Panel
* Authentication & Authorization * i18n i L10n * Cache
* Forms
Mimari MTV (Model, Template, View)
Model from django.db import models class class Poll(models.Model): question =
models.CharField(max_length=200) pub_date = models.DateTimeField('date published') class Choice(models.Model): poll = models.ForeignKey(Poll) choice = models.CharField(max_length=200) votes = models.IntegerField()
ORM >>> from polls.models import Poll, Choice >>> Poll.objects.all() []
>>> import datetime >>> p = Poll(question="Naber?", ... pub_date=datetime.datetime.now()) >>> p.save() >>> p.id 1 >>> p.question "Naber?"
orm devam >>> Poll.objects.get(id=1) <Poll: Naber?> >>> Poll.objects.filter(question="Naber?") [<Poll: Naber?>]
>>> Poll.objects.all().order_by("question") [<Poll: Naber?>] >>> Poll.objects.filter(question__startswith="Nab") [<Poll: Naber?>]
>>> p = Poll.objects.get(question="Naber?") >>> p.question = "Naber Django?" >>>
p.save() >>> p.question
Admin Panel
None
Views from django.http import HttpResponse def hello(request): return HttpResponse("Hello World!")
from django.shortcuts import render_to_response from polls.models import * def index(request): latest_poll_list = Poll.objects.all().order_by('-pub_date') return render_to_response('index.html', {'latest_poll_list': latest_poll_list})
URLconfs from django.conf.urls.defaults import * urlpatterns = patterns(''", (r'^polls/$', 'polls.views.index'),
) example.com/polls/
Templates
Örnek uygulama https://github.com/cihann/djangoistanbul
[email protected]
:cihann/djangoistanbul.git
TEŞEKKÜRLER SORULAR?