1
0
mirror of https://github.com/django/django.git synced 2025-07-05 18:29:11 +00:00

magic-removal: Removed 'New in Django development version' notes in all docs

git-svn-id: http://code.djangoproject.com/svn/django/branches/magic-removal@2744 bcc190cf-cafb-0310-a4f2-bffc1f526a37
This commit is contained in:
Adrian Holovaty 2006-04-24 00:29:31 +00:00
parent 0f89743539
commit 489d5bae5c
9 changed files with 84 additions and 136 deletions

View File

@ -28,11 +28,13 @@ Column Types
.. admonition:: Note .. admonition:: Note
In the Django development version, all admin pages (except the dashboard) are fluid-width. All fixed-width classes have been removed. All admin pages (except the dashboard) are fluid-width. All fixed-width
classes from previous Django versions have been removed.
The base template for each admin page has a block that defines the column The base template for each admin page has a block that defines the column
structure for the page. This sets a class on the page content area structure for the page. This sets a class on the page content area
(``div#content``) so everything on the page knows how wide it should be. There are three column types available. (``div#content``) so everything on the page knows how wide it should be. There
are three column types available.
colM colM
This is the default column setting for all pages. The "M" stands for "main". This is the default column setting for all pages. The "M" stands for "main".
@ -46,39 +48,12 @@ colMS
colSM colSM
Same as above, with the sidebar on the left. The source order of the columns Same as above, with the sidebar on the left. The source order of the columns
doesn't matter. doesn't matter.
colM superwide (removed in Django development version)
This is for ridiculously wide pages. Doesn't really work very well for
anything but colM. With superwide, you've got 1000px to work with. Don't
waste them.
flex (removed in Django development version)
This is for liquid-width pages, such as changelists. Currently only works
with single-column pages (does not combine with ``.colMS`` or ``.colSM``).
Form pages should never use ``.flex``.
For instance, you could stick this in a template to make a two-column page with the sidebar on the right:: For instance, you could stick this in a template to make a two-column page with
the sidebar on the right::
{% block coltype %}colMS{% endblock %} {% block coltype %}colMS{% endblock %}
Widths
======
**Removed in Django development version (see note above).**
There's a whole mess of classes in the stylesheet for custom pixel widths on
objects. They come in handy for tables and table cells, if you want to avoid
using the ``width`` attribute. Each class sets the width to the number of pixels
in the class, except ``.xfull`` which will always be the width of the column
it's in. (This helps with tables that you want to always fill the horizontal
width, without using ``width="100%"`` which makes IE 5's box model cry.)
**Note:** Within a ``.flex`` page, the ``.xfull`` class will ``usually`` set
to 100%, but there are exceptions and still some untested cases.
Available width classes::
.x50 .x75 .x100 .x150 .x200 .x250 .x300 .x400 .x500 .xfull
Text Styles Text Styles
=========== ===========
@ -107,17 +82,18 @@ There are also a few styles for styling text.
.help .help
This is a custom class for blocks of inline help text explaining the This is a custom class for blocks of inline help text explaining the
function of form elements. It makes text smaller and gray, and when applied function of form elements. It makes text smaller and gray, and when applied
to ``p`` elements withing ``.form-row`` elements (see Form Styles below), it will to ``p`` elements withing ``.form-row`` elements (see Form Styles below),
offset the text to align with the form field. Use this for help text, it will offset the text to align with the form field. Use this for help
instead of ``small quiet``. It works on other elements, but try to put the class text, instead of ``small quiet``. It works on other elements, but try to
on a ``p`` whenever you can. put the class on a ``p`` whenever you can.
.align-left .align-left
It aligns the text left. Only works on block elements containing inline elements. It aligns the text left. Only works on block elements containing inline
elements.
.align-right .align-right
Are you paying attention? Are you paying attention?
.nowrap .nowrap
Keeps text and inline objects from wrapping. Comes in handy for table headers you want to stay Keeps text and inline objects from wrapping. Comes in handy for table
on one line. headers you want to stay on one line.
Floats and Clears Floats and Clears
----------------- -----------------
@ -173,9 +149,10 @@ Each fieldset can also take extra classes in addition to ``.module`` to apply
appropriate formatting to the group of fields. appropriate formatting to the group of fields.
.aligned .aligned
this will align the labels and inputs side by side on the same line. This will align the labels and inputs side by side on the same line.
.wide .wide
used in combination with ``.aligned`` to widen the space available for the labels. Used in combination with ``.aligned`` to widen the space available for the
labels.
Form Rows Form Rows
--------- ---------

View File

@ -110,12 +110,12 @@ output:
``'This field type is a guess.'`` next to the field in the generated ``'This field type is a guess.'`` next to the field in the generated
model. model.
* **New in Django development version.** If the database column name is a * If the database column name is a Python reserved word (such as
Python reserved word (such as ``'pass'``, ``'class'`` or ``'for'``), ``'pass'``, ``'class'`` or ``'for'``), ``inspectdb`` will append
``inspectdb`` will append ``'_field'`` to the attribute name. For ``'_field'`` to the attribute name. For example, if a table has a column
example, if a table has a column ``'for'``, the generated model will have ``'for'``, the generated model will have a field ``'for_field'``, with
a field ``'for_field'``, with the ``db_column`` attribute set to the ``db_column`` attribute set to ``'for'``. ``inspectdb`` will insert
``'for'``. ``inspectdb`` will insert the Python comment the Python comment
``'Field renamed because it was a Python reserved word.'`` next to the ``'Field renamed because it was a Python reserved word.'`` next to the
field. field.
@ -180,9 +180,9 @@ shell
Starts the Python interactive interpreter. Starts the Python interactive interpreter.
**New in Django development version:** Uses IPython_, if it's installed. If you Django will use IPython_, if it's installed. If you have IPython installed and
have IPython installed and want to force use of the "plain" Python interpreter, want to force use of the "plain" Python interpreter, use the ``--plain``
use the ``--plain`` option, like so:: option, like so::
django-admin.py shell --plain django-admin.py shell --plain

View File

@ -42,13 +42,12 @@ are required.
* ``fail_silently``: A boolean. If it's ``False``, ``send_mail`` will raise * ``fail_silently``: A boolean. If it's ``False``, ``send_mail`` will raise
an ``smtplib.SMTPException``. See the `smtplib docs`_ for a list of an ``smtplib.SMTPException``. See the `smtplib docs`_ for a list of
possible exceptions, all of which are subclasses of ``SMTPException``. possible exceptions, all of which are subclasses of ``SMTPException``.
* ``auth_user``: **New in Django development version.** The optional * ``auth_user``: The optional username to use to authenticate to the SMTP
username to use to authenticate to the SMTP server. If this isn't server. If this isn't provided, Django will use the value of the
provided, Django will use the value of the ``EMAIL_HOST_USER`` setting. ``EMAIL_HOST_USER`` setting.
* ``auth_password``: **New in Django development version.** The optional * ``auth_password``: The optional password to use to authenticate to the
password to use to authenticate to the SMTP server. If this isn't SMTP server. If this isn't provided, Django will use the value of the
provided, Django will use the value of the ``EMAIL_HOST_PASSWORD`` ``EMAIL_HOST_PASSWORD`` setting.
setting.
.. _smtplib docs: http://www.python.org/doc/current/lib/module-smtplib.html .. _smtplib docs: http://www.python.org/doc/current/lib/module-smtplib.html
@ -66,8 +65,7 @@ Here's the definition::
(subject, message, from_email, recipient_list) (subject, message, from_email, recipient_list)
``fail_silently``, ``auth_user`` and ``auth_password`` have the same functions ``fail_silently``, ``auth_user`` and ``auth_password`` have the same functions
as in ``send_mail()``. Note that ``auth_user`` and ``auth_password`` are only as in ``send_mail()``.
available in the Django development version.
Each separate element of ``datatuple`` results in a separate e-mail message. Each separate element of ``datatuple`` results in a separate e-mail message.
As in ``send_mail()``, recipients in the same ``recipient_list`` will all see As in ``send_mail()``, recipients in the same ``recipient_list`` will all see

View File

@ -189,9 +189,8 @@ The date-based generic functions are:
Takes an optional ``allow_empty`` parameter, as ``archive_index``. Takes an optional ``allow_empty`` parameter, as ``archive_index``.
**New in Django development version:** Takes an optional Takes an optional ``template_object_name`` parameter, which designates the
``template_object_name`` parameter, which designates the name of the name of the template variable to use. Default is ``'object'``.
template variable to use. Default is ``'object'``.
Uses the template ``<app_label>/<model_name>_archive_month.html`` by default. Uses the template ``<app_label>/<model_name>_archive_month.html`` by default.
@ -200,18 +199,17 @@ The date-based generic functions are:
``month`` ``month``
The given month (a datetime.date object) The given month (a datetime.date object)
``next_month`` ``next_month``
**New in Django development version.** The first day of the next The first day of the next month, or None if the next month is in
month, or None if the next month is in the future (a datetime.date the future (a datetime.date object)
object)
``previous_month`` ``previous_month``
**New in Django development version.** The first day of the The first day of the previous month (a datetime.date object)
previous month (a datetime.date object)
``object_list`` ``object_list``
List of objects published in the given month. List of objects published in the given month.
In the Django development version, you can change this variable
name from ``object_list`` by using the ``template_object_name`` You can change this variable name from ``object_list`` by using the
parameter. (See above.) For example, if ``template_object_name`` is ``template_object_name`` parameter. (See above.) For example, if
``foo``, the variable will be ``foo_list``. ``template_object_name`` is ``foo``, the variable will be
``foo_list``.
``archive_week`` ``archive_week``
Weekly archive. Requires that ``year`` and ``week`` arguments be given. The Weekly archive. Requires that ``year`` and ``week`` arguments be given. The
@ -242,9 +240,8 @@ The date-based generic functions are:
also pass ``day_format``, which defaults to ``"%d"`` (day of the month as a also pass ``day_format``, which defaults to ``"%d"`` (day of the month as a
decimal number, 1-31). decimal number, 1-31).
**New in Django development version:** Takes an optional Takes an optional ``template_object_name`` parameter, which designates the
``template_object_name`` parameter, which designates the name of the name of the template variable to use. Default is ``'object'``.
template variable to use. Default is ``'object'``.
Uses the template ``<app_label>/<model_name>_archive_day.html`` by default. Uses the template ``<app_label>/<model_name>_archive_day.html`` by default.
@ -252,10 +249,11 @@ The date-based generic functions are:
``object_list`` ``object_list``
List of objects published on the given day. List of objects published on the given day.
In the Django development version, you can change this variable
name from ``object_list`` by using the ``template_object_name`` You can change this variable name from ``object_list`` by using the
parameter. (See above.) For example, if ``template_object_name`` is ``template_object_name`` parameter. (See above.) For example, if
``foo``, the variable will be ``foo_list``. ``template_object_name`` is ``foo``, the variable will be
``foo_list``.
``day`` ``day``
The given day (a datetime.datetime object) The given day (a datetime.datetime object)
``previous_day`` ``previous_day``
@ -287,9 +285,8 @@ The date-based generic functions are:
As in ``archive_day``, ``object_detail`` takes optional ``month_format`` As in ``archive_day``, ``object_detail`` takes optional ``month_format``
and ``day_format`` parameters. and ``day_format`` parameters.
**New in Django development version:** Takes an optional Takes an optional ``template_object_name`` parameter, which designates the
``template_object_name`` parameter, which designates the name of the name of the template variable to use. Default is ``'object'``.
template variable to use. Default is ``'object'``.
.. _strftime docs: http://www.python.org/doc/current/lib/module-time.html#l2h-1941 .. _strftime docs: http://www.python.org/doc/current/lib/module-time.html#l2h-1941
@ -323,9 +320,8 @@ Individual views are:
the view will raise a 404 instead of displaying the view will raise a 404 instead of displaying
an empty index page. ``False`` is default. an empty index page. ``False`` is default.
``template_object_name`` **New in Django development version.** Designates ``template_object_name`` Designates the name of the object template
the name of the object template variable. Default variable. Default is ``'object'``.
is ``'object'``.
======================== ================================================= ======================== =================================================
Uses the template ``<app_label>/<module_name_list>.html`` by default. Uses the template ``<app_label>/<module_name_list>.html`` by default.
@ -333,8 +329,9 @@ Individual views are:
Has the following template context: Has the following template context:
``object_list`` ``object_list``
List of objects. In the Django development version, you can change List of objects.
this variable name from ``object_list`` by using the
You can change this variable name from ``object_list`` by using the
``template_object_name`` parameter. (See above.) For example, if ``template_object_name`` parameter. (See above.) For example, if
``template_object_name`` is ``foo``, the variable will be ``template_object_name`` is ``foo``, the variable will be
``foo_list``. ``foo_list``.
@ -407,9 +404,8 @@ The create/update/delete views are:
``list_detail.object_detail`` does (see above), and the same ``list_detail.object_detail`` does (see above), and the same
``post_save_redirect`` as ``create_object`` does. ``post_save_redirect`` as ``create_object`` does.
**New in Django development version:** Takes an optional Takes an optional ``template_object_name`` parameter, which designates the
``template_object_name`` parameter, which designates the name of the name of the template variable to use. Default is ``'object'``.
template variable to use. Default is ``'object'``.
Uses the template ``<app_label>/<model_name>_form.html`` by default. Uses the template ``<app_label>/<model_name>_form.html`` by default.
@ -419,10 +415,11 @@ The create/update/delete views are:
The form wrapper for the object The form wrapper for the object
object object
The original object being edited. The original object being edited.
In the Django development version, you can change this variable
name from ``object`` by using the ``template_object_name`` You can change this variable name from ``object`` by using the
parameter. (See above.) For example, if ``template_object_name`` is ``template_object_name`` parameter. (See above.) For example, if
``foo``, the variable will be ``foo`` instead of ``object``. ``template_object_name`` is ``foo``, the variable will be ``foo``
instead of ``object``.
``delete_object`` ``delete_object``
Delete an existing object. The given object will only actually be deleted Delete an existing object. The given object will only actually be deleted
@ -437,15 +434,15 @@ The create/update/delete views are:
``<app_label>/<model_name>_confirm_delete`` by default. It uses no template ``<app_label>/<model_name>_confirm_delete`` by default. It uses no template
if POSTed -- it simply deletes the object and redirects. if POSTed -- it simply deletes the object and redirects.
**New in Django development version:** Takes an optional Takes an optional ``template_object_name`` parameter, which designates the
``template_object_name`` parameter, which designates the name of the name of the template variable to use. Default is ``'object'``.
template variable to use. Default is ``'object'``.
Has the following template context: Has the following template context:
object object
The object about to be deleted The object about to be deleted.
In the Django development version, you can change this variable
name from ``object`` by using the ``template_object_name`` You can change this variable name from ``object`` by using the
parameter. (See above.) For example, if ``template_object_name`` is ``template_object_name`` parameter. (See above.) For example, if
``foo``, the variable will be ``foo`` instead of ``object``. ``template_object_name`` is ``foo``, the variable will be ``foo``
instead of ``object``.

View File

@ -304,9 +304,9 @@ Methods
Instantiates an ``HttpResponse`` object with the given page content (a Instantiates an ``HttpResponse`` object with the given page content (a
string) and MIME type. The ``DEFAULT_MIME_TYPE`` is ``"text/html"``. string) and MIME type. The ``DEFAULT_MIME_TYPE`` is ``"text/html"``.
**New in Django development version:** ``content`` can be an iterator ``content`` can be an iterator or a string. If it's an iterator, it should
instead of a string. This iterator should return strings, and those strings return strings, and those strings will be joined together to form the
will be joined together to form the content of the response. content of the response.
``__setitem__(header, value)`` ``__setitem__(header, value)``
Sets the given header name to the given value. Both ``header`` and Sets the given header name to the given value. Both ``header`` and
@ -343,14 +343,10 @@ Methods
Deletes the cookie with the given key. Fails silently if the key doesn't Deletes the cookie with the given key. Fails silently if the key doesn't
exist. exist.
``get_content_as_string(encoding)``
Returns the content as a Python string, encoding it from a Unicode object
if necessary. **Removed in Django development version.**
``content`` ``content``
**New in Django development version.** Returns the content as a Python Returns the content as a Python string, encoding it from a Unicode object
string, encoding it from a Unicode object if necessary. Note this is a if necessary. Note this is a property, not a method, so use ``r.content``
property, not a method, so use ``r.content`` instead of ``r.content()``. instead of ``r.content()``.
``write(content)``, ``flush()`` and ``tell()`` ``write(content)``, ``flush()`` and ``tell()``
These methods make an ``HttpResponse`` instance a file-like object. These methods make an ``HttpResponse`` instance a file-like object.

View File

@ -46,10 +46,8 @@ It implements the following standard dictionary methods:
Example: ``fav_color = request.session.get('fav_color', 'red')`` Example: ``fav_color = request.session.get('fav_color', 'red')``
* ``keys()`` * ``keys()``
**New in Django development version.**
* ``items()`` * ``items()``
**New in Django development version.**
It also has these three methods: It also has these three methods:

View File

@ -363,8 +363,6 @@ EMAIL_HOST_PASSWORD
Default: ``''`` (Empty string) Default: ``''`` (Empty string)
**New in Django development version.**
Username to use for the SMTP server defined in ``EMAIL_HOST``. If empty, Username to use for the SMTP server defined in ``EMAIL_HOST``. If empty,
Django won't attempt authentication. Django won't attempt authentication.
@ -375,8 +373,6 @@ EMAIL_HOST_USER
Default: ``''`` (Empty string) Default: ``''`` (Empty string)
**New in Django development version.**
Username to use for the SMTP server defined in ``EMAIL_HOST``. If empty, Username to use for the SMTP server defined in ``EMAIL_HOST``. If empty,
Django won't attempt authentication. Django won't attempt authentication.
@ -387,8 +383,6 @@ EMAIL_PORT
Default: ``25`` Default: ``25``
**New in Django development version.**
Port to use for the SMTP server defined in ``EMAIL_HOST``. Port to use for the SMTP server defined in ``EMAIL_HOST``.
EMAIL_SUBJECT_PREFIX EMAIL_SUBJECT_PREFIX
@ -405,8 +399,6 @@ ENABLE_PSYCO
Default: ``False`` Default: ``False``
**New in Django development version.**
Whether to enable Psyco, which optimizes Python code. Requires Psyco_. Whether to enable Psyco, which optimizes Python code. Requires Psyco_.
.. _Psyco: http://psyco.sourceforge.net/ .. _Psyco: http://psyco.sourceforge.net/
@ -676,8 +668,6 @@ TEMPLATE_STRING_IF_INVALID
Default: ``''`` (Empty string) Default: ``''`` (Empty string)
**New in Django development version.**
Output, as a string, that the template system should use for invalid (e.g. Output, as a string, that the template system should use for invalid (e.g.
misspelled) variables. See `How invalid variables are handled`_. misspelled) variables. See `How invalid variables are handled`_.

View File

@ -70,9 +70,7 @@ Use a dot (``.``) to access attributes of a variable.
In the above example, ``{{ section.title }}`` will be replaced with the In the above example, ``{{ section.title }}`` will be replaced with the
``title`` attribute of the ``section`` object. ``title`` attribute of the ``section`` object.
In Django 0.91, if you use a variable that doesn't exist, it will be silently If you use a variable that doesn't exist, the template system will insert
ignored; the variable will be replaced by nothingness. In the Django
development version, if a variable doesn't exist, the template system inserts
the value of the ``TEMPLATE_STRING_IF_INVALID`` setting, which is set to ``''`` the value of the ``TEMPLATE_STRING_IF_INVALID`` setting, which is set to ``''``
(the empty string) by default. (the empty string) by default.
@ -247,10 +245,8 @@ Because Django can be used to develop any sort of site, the tags, filters and
variables available are different depending on the application. To make it variables available are different depending on the application. To make it
easy to figure out what's available in a given site, the admin interface has a easy to figure out what's available in a given site, the admin interface has a
complete reference of all the template goodies available to that site. To get complete reference of all the template goodies available to that site. To get
that reference, go to your Django admin interface and append ``'doc'`` onto the that reference, go to your Django admin interface and click the "Documentation"
admin URL. Example: ``http://127.0.0.1/admin/doc/``. In the Django development link in the upper right of any page.
version, you'll see a "Documentation" link in the upper right of every
admin-site page.
The reference is integrated into the administration interface for your site(s) The reference is integrated into the administration interface for your site(s)
and is divided into 4 sections: tags, filters, models, and views. and is divided into 4 sections: tags, filters, models, and views.
@ -693,8 +689,6 @@ i.e.::
spaceless spaceless
~~~~~~~~~ ~~~~~~~~~
**New in Django development version.**
Normalizes whitespace between HTML tags to a single space. This includes tab Normalizes whitespace between HTML tags to a single space. This includes tab
characters and newlines. characters and newlines.

View File

@ -209,9 +209,9 @@ This applies to any level of lookup::
>>> t.render(c) >>> t.render(c)
"My name is Stan ." "My name is Stan ."
In the Django development version, if a variable doesn't exist, the template If a variable doesn't exist, the template system inserts the value of the
system inserts the value of the ``TEMPLATE_STRING_IF_INVALID`` setting, which ``TEMPLATE_STRING_IF_INVALID`` setting, which is set to ``''`` (the empty
is set to ``''`` (the empty string) by default. string) by default.
Playing with Context objects Playing with Context objects
---------------------------- ----------------------------
@ -352,8 +352,6 @@ See the `internationalization docs`_ for more.
django.core.context_processors.request django.core.context_processors.request
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
**New in Django development version**
If ``TEMPLATE_CONTEXT_PROCESSORS`` contains this processor, every If ``TEMPLATE_CONTEXT_PROCESSORS`` contains this processor, every
``DjangoContext`` will contain a variable ``request``, which is the current ``DjangoContext`` will contain a variable ``request``, which is the current
`HttpRequest object`_. Note that this processor is not enabled by default; `HttpRequest object`_. Note that this processor is not enabled by default;