Skip to content

Commit

Permalink
Revise section "Pre-Traversal Hook"
Browse files Browse the repository at this point in the history
- improve formatting

modified:   docs/zdgbook/ObjectPublishing.rst
  • Loading branch information
jugmac00 committed Dec 28, 2018
1 parent 9bf1433 commit 8f5ba94
Showing 1 changed file with 10 additions and 10 deletions.
20 changes: 10 additions & 10 deletions docs/zdgbook/ObjectPublishing.rst
Original file line number Diff line number Diff line change
Expand Up @@ -376,18 +376,18 @@ Pre-Traversal Hook
------------------

The pre-traversal hook allows your objects to take special action
before they are traversed. This is useful for doing things like
changing the request. Applications of this include special
authentication controls, and virtual hosting support.

If your object has a method named '__before_publishing_traverse__',
the publisher will call it with the current object and the request,
before traversing your object. Most often your method will change the
request. The publisher ignores anything you return from the
before they are traversed. This is useful for doing things like
changing the request. Applications of this include special
authentication controls and virtual hosting support.

If your object has a method named ``__before_publishing_traverse__``,
the publisher will call it with the current object and the request
before traversing your object. Most often your method will change the
request. The publisher ignores anything you return from the
pre-traversal hook method.

The 'ZPublisher.BeforeTraverse' module contains some functions that
help you register pre-traversal callbacks. This allows you to perform
The ``ZPublisher.BeforeTraverse`` module contains some functions that
help you register pre-traversal callbacks. This allows you to perform
fairly complex callbacks to multiple objects when a given object is
about to be traversed.

Expand Down

0 comments on commit 8f5ba94

Please sign in to comment.