Fixed #4814 -- Fixed some whitespace issues in tutorial01, thanks John Shaffer.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@5639 bcc190cf-cafb-0310-a4f2-bffc1f526a37
This commit is contained in:
Gary Wilson Jr 2007-07-10 02:45:11 +00:00
parent 0be6d32c24
commit 541c9ff797
1 changed files with 15 additions and 15 deletions

View File

@ -500,10 +500,10 @@ admin.
default. All data stored in your database is converted to Unicode when it's default. All data stored in your database is converted to Unicode when it's
returned. returned.
Django models have a default ``__str__()`` method that calls ``__unicode__()`` Django models have a default ``__str__()`` method that calls
and converts the result to a UTF-8 bytestring. This means that ``unicode(p)`` ``__unicode__()`` and converts the result to a UTF-8 bytestring. This means
will return a Unicode string, and ``str(p)`` will return a normal string, that ``unicode(p)`` will return a Unicode string, and ``str(p)`` will return
with characters encoded as UTF-8. a normal string, with characters encoded as UTF-8.
If all of this is jibberish to you, just remember to add ``__unicode__()`` If all of this is jibberish to you, just remember to add ``__unicode__()``
methods to your models. With any luck, things should Just Work for you. methods to your models. With any luck, things should Just Work for you.