Ticket #5097: overview.txt.diff

File overview.txt.diff, 1.3 KB (added by Nicola Larosa <nico@…>, 17 years ago)
  • overview.txt

     
    5454==================
    5555
    5656With that, you've got a free, and rich, Python API to access your data. The API
    57 is created on the fly: No code generation necessary::
     57is created on the fly, no code generation necessary::
    5858
    5959    >>> from mysite.models import Reporter, Article
    6060
     
    124124    # Delete an object with delete().
    125125    >>> r.delete()
    126126
    127 A dynamic admin interface: It's not just scaffolding -- it's the whole house
     127A dynamic admin interface: it's not just scaffolding -- it's the whole house
    128128============================================================================
    129129
    130130Once your models are defined, Django can automatically create a professional,
     
    250250``{% extends "base.html" %}`` does. It means "First load the template called
    251251'base', which has defined a bunch of blocks, and fill the blocks with the
    252252following blocks." In short, that lets you dramatically cut down on redundancy
    253 in templates: Each template has to define only what's unique to that template.
     253in templates: each template has to define only what's unique to that template.
    254254
    255255Here's what the "base.html" template might look like::
    256256
Back to Top