diff --git a/docs/howto/custom-template-tags.txt b/docs/howto/custom-template-tags.txt
index e1ddefe..99e4b29 100644
a
|
b
|
Now your tag should begin to look like this::
|
525 | 525 | |
526 | 526 | You also have to change the renderer to retrieve the actual contents of the |
527 | 527 | ``date_updated`` property of the ``blog_entry`` object. This can be |
528 | | accomplished by using the ``resolve_variable()`` function in |
529 | | ``django.template``. You pass ``resolve_variable()`` the variable name and the |
| 528 | accomplished by using the ``Variable`` class in ``django.template``. |
| 529 | You pass ``template.Variable`` the variable name and later call the |
| 530 | returned ``Variable`` instance method ``resolve`` using the |
530 | 531 | current context, available in the ``render`` method:: |
531 | 532 | |
532 | 533 | from django import template |
533 | | from django.template import resolve_variable |
534 | 534 | import datetime |
535 | 535 | class FormatTimeNode(template.Node): |
536 | 536 | def __init__(self, date_to_be_formatted, format_string): |
537 | | self.date_to_be_formatted = date_to_be_formatted |
| 537 | self.date_to_be_formatted = template.Variable(date_to_be_formatted) |
538 | 538 | self.format_string = format_string |
539 | 539 | |
540 | 540 | def render(self, context): |
541 | 541 | try: |
542 | | actual_date = resolve_variable(self.date_to_be_formatted, context) |
| 542 | actual_date = self.date_to_be_formatted.resolve(context) |
543 | 543 | return actual_date.strftime(self.format_string) |
544 | 544 | except template.VariableDoesNotExist: |
545 | 545 | return '' |
546 | 546 | |
547 | | ``resolve_variable`` will try to resolve ``blog_entry.date_updated`` and then |
548 | | format it accordingly. |
| 547 | The ``Variable`` instance self.date_to_be_formatted method ``resolve``, will |
| 548 | try to resolve ``blog_entry.date_updated`` and then format it accordingly. |
549 | 549 | |
550 | 550 | .. versionadded:: 1.0 |
551 | 551 | |