parts/django/docs/faq/general.txt
changeset 69 c6bca38c1cbf
equal deleted inserted replaced
68:5ff1fc726848 69:c6bca38c1cbf
       
     1 FAQ: General
       
     2 ============
       
     3 
       
     4 Why does this project exist?
       
     5 ----------------------------
       
     6 
       
     7 Django grew from a very practical need: World Online, a newspaper Web
       
     8 operation, is responsible for building intensive Web applications on journalism
       
     9 deadlines. In the fast-paced newsroom, World Online often has only a matter of
       
    10 hours to take a complicated Web application from concept to public launch.
       
    11 
       
    12 At the same time, the World Online Web developers have consistently been
       
    13 perfectionists when it comes to following best practices of Web development.
       
    14 
       
    15 In fall 2003, the World Online developers (Adrian Holovaty and Simon Willison)
       
    16 ditched PHP and began using Python to develop its Web sites. As they built
       
    17 intensive, richly interactive sites such as Lawrence.com, they began to extract
       
    18 a generic Web development framework that let them build Web applications more
       
    19 and more quickly. They tweaked this framework constantly, adding improvements
       
    20 over two years.
       
    21 
       
    22 In summer 2005, World Online decided to open-source the resulting software,
       
    23 Django. Django would not be possible without a whole host of open-source
       
    24 projects -- `Apache`_, `Python`_, and `PostgreSQL`_ to name a few -- and we're
       
    25 thrilled to be able to give something back to the open-source community.
       
    26 
       
    27 .. _Apache: http://httpd.apache.org/
       
    28 .. _Python: http://www.python.org/
       
    29 .. _PostgreSQL: http://www.postgresql.org/
       
    30 
       
    31 What does "Django" mean, and how do you pronounce it?
       
    32 -----------------------------------------------------
       
    33 
       
    34 Django is named after `Django Reinhardt`_, a gypsy jazz guitarist from the 1930s
       
    35 to early 1950s. To this day, he's considered one of the best guitarists of all time.
       
    36 
       
    37 Listen to his music. You'll like it.
       
    38 
       
    39 Django is pronounced **JANG**-oh. Rhymes with FANG-oh. The "D" is silent.
       
    40 
       
    41 We've also recorded an `audio clip of the pronunciation`_.
       
    42 
       
    43 .. _Django Reinhardt: http://en.wikipedia.org/wiki/Django_Reinhardt
       
    44 .. _audio clip of the pronunciation: http://red-bean.com/~adrian/django_pronunciation.mp3
       
    45 
       
    46 Is Django stable?
       
    47 -----------------
       
    48 
       
    49 Yes. World Online has been using Django for more than three years. Sites built
       
    50 on Django have weathered traffic spikes of over one million hits an hour and a
       
    51 number of Slashdottings. Yes, it's quite stable.
       
    52 
       
    53 Does Django scale?
       
    54 ------------------
       
    55 
       
    56 Yes. Compared to development time, hardware is cheap, and so Django is
       
    57 designed to take advantage of as much hardware as you can throw at it.
       
    58 
       
    59 Django uses a "shared-nothing" architecture, which means you can add hardware
       
    60 at any level -- database servers, caching servers or Web/application servers.
       
    61 
       
    62 The framework cleanly separates components such as its database layer and
       
    63 application layer. And it ships with a simple-yet-powerful
       
    64 :doc:`cache framework </topics/cache>`.
       
    65 
       
    66 Who's behind this?
       
    67 ------------------
       
    68 
       
    69 Django was originally developed at World Online, the Web department of a
       
    70 newspaper in Lawrence, Kansas, USA. Django's now run by an international team of
       
    71 volunteers; you can read all about them over at the :doc:`list of committers
       
    72 </internals/committers>`
       
    73 
       
    74 Which sites use Django?
       
    75 -----------------------
       
    76 
       
    77 The Django wiki features a consistently growing `list of Django-powered sites`_.
       
    78 Feel free to add your Django-powered site to the list.
       
    79 
       
    80 .. _list of Django-powered sites: http://code.djangoproject.com/wiki/DjangoPoweredSites
       
    81 
       
    82 .. _mtv:
       
    83 
       
    84 Django appears to be a MVC framework, but you call the Controller the "view", and the View the "template". How come you don't use the standard names?
       
    85 -----------------------------------------------------------------------------------------------------------------------------------------------------
       
    86 
       
    87 Well, the standard names are debatable.
       
    88 
       
    89 In our interpretation of MVC, the "view" describes the data that gets presented
       
    90 to the user. It's not necessarily *how* the data *looks*, but *which* data is
       
    91 presented. The view describes *which data you see*, not *how you see it.* It's
       
    92 a subtle distinction.
       
    93 
       
    94 So, in our case, a "view" is the Python callback function for a particular URL,
       
    95 because that callback function describes which data is presented.
       
    96 
       
    97 Furthermore, it's sensible to separate content from presentation -- which is
       
    98 where templates come in. In Django, a "view" describes which data is presented,
       
    99 but a view normally delegates to a template, which describes *how* the data is
       
   100 presented.
       
   101 
       
   102 Where does the "controller" fit in, then? In Django's case, it's probably the
       
   103 framework itself: the machinery that sends a request to the appropriate view,
       
   104 according to the Django URL configuration.
       
   105 
       
   106 If you're hungry for acronyms, you might say that Django is a "MTV" framework
       
   107 -- that is, "model", "template", and "view." That breakdown makes much more
       
   108 sense.
       
   109 
       
   110 At the end of the day, of course, it comes down to getting stuff done. And,
       
   111 regardless of how things are named, Django gets stuff done in a way that's most
       
   112 logical to us.
       
   113 
       
   114 <Framework X> does <feature Y> -- why doesn't Django?
       
   115 -----------------------------------------------------
       
   116 
       
   117 We're well aware that there are other awesome Web frameworks out there, and
       
   118 we're not averse to borrowing ideas where appropriate. However, Django was
       
   119 developed precisely because we were unhappy with the status quo, so please be
       
   120 aware that "because <Framework X> does it" is not going to be sufficient reason
       
   121 to add a given feature to Django.
       
   122 
       
   123 Why did you write all of Django from scratch, instead of using other Python libraries?
       
   124 --------------------------------------------------------------------------------------
       
   125 
       
   126 When Django was originally written a couple of years ago, Adrian and Simon
       
   127 spent quite a bit of time exploring the various Python Web frameworks
       
   128 available.
       
   129 
       
   130 In our opinion, none of them were completely up to snuff.
       
   131 
       
   132 We're picky. You might even call us perfectionists. (With deadlines.)
       
   133 
       
   134 Over time, we stumbled across open-source libraries that did things we'd
       
   135 already implemented. It was reassuring to see other people solving similar
       
   136 problems in similar ways, but it was too late to integrate outside code: We'd
       
   137 already written, tested and implemented our own framework bits in several
       
   138 production settings -- and our own code met our needs delightfully.
       
   139 
       
   140 In most cases, however, we found that existing frameworks/tools inevitably had
       
   141 some sort of fundamental, fatal flaw that made us squeamish. No tool fit our
       
   142 philosophies 100%.
       
   143 
       
   144 Like we said: We're picky.
       
   145 
       
   146 We've documented our philosophies on the
       
   147 :doc:`design philosophies page </misc/design-philosophies>`.
       
   148 
       
   149 Is Django a content-management-system (CMS)?
       
   150 --------------------------------------------
       
   151 
       
   152 No, Django is not a CMS, or any sort of "turnkey product" in and of itself.
       
   153 It's a Web framework; it's a programming tool that lets you build Web sites.
       
   154 
       
   155 For example, it doesn't make much sense to compare Django to something like
       
   156 Drupal_, because Django is something you use to *create* things like Drupal.
       
   157 
       
   158 Of course, Django's automatic admin site is fantastic and timesaving -- but
       
   159 the admin site is one module of Django the framework. Furthermore, although
       
   160 Django has special conveniences for building "CMS-y" apps, that doesn't mean
       
   161 it's not just as appropriate for building "non-CMS-y" apps (whatever that
       
   162 means!).
       
   163 
       
   164 .. _Drupal: http://drupal.org/
       
   165 
       
   166 How can I download the Django documentation to read it offline?
       
   167 ---------------------------------------------------------------
       
   168 
       
   169 The Django docs are available in the ``docs`` directory of each Django tarball
       
   170 release. These docs are in reST (reStructuredText) format, and each text file
       
   171 corresponds to a Web page on the official Django site.
       
   172 
       
   173 Because the documentation is `stored in revision control`_, you can browse
       
   174 documentation changes just like you can browse code changes.
       
   175 
       
   176 Technically, the docs on Django's site are generated from the latest development
       
   177 versions of those reST documents, so the docs on the Django site may offer more
       
   178 information than the docs that come with the latest Django release.
       
   179 
       
   180 .. _stored in revision control: http://code.djangoproject.com/browser/django/trunk/docs
       
   181 
       
   182 Where can I find Django developers for hire?
       
   183 --------------------------------------------
       
   184 
       
   185 Consult our `developers for hire page`_ for a list of Django developers who
       
   186 would be happy to help you.
       
   187 
       
   188 You might also be interested in posting a job to http://djangogigs.com/ .
       
   189 If you want to find Django-capable people in your local area, try
       
   190 http://djangopeople.net/ .
       
   191 
       
   192 .. _developers for hire page: http://code.djangoproject.com/wiki/DevelopersForHire