Skip to content

Commit cc15903

Browse files
committed
docs: add explanation for "global response instance"
1 parent 6ead627 commit cc15903

1 file changed

Lines changed: 5 additions & 2 deletions

File tree

user_guide_src/source/outgoing/response.rst

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,11 @@ a server responding to the client that called it.
1212
Working with the Response
1313
=========================
1414

15-
A Response class is instantiated for you and passed into your controllers. It can be accessed through
16-
``$this->response``. Many times you will not need to touch the class directly, since CodeIgniter takes care of
15+
A Response class is instantiated for you and passed into your controllers. It can
16+
be accessed through ``$this->response``. It is the same instance that
17+
``Services::response()`` returns. We call it the global response instance.
18+
19+
Many times you will not need to touch the class directly, since CodeIgniter takes care of
1720
sending the headers and the body for you. This is great if the page successfully created the content it was asked to.
1821
When things go wrong, or you need to send very specific status codes back, or even take advantage of the
1922
powerful HTTP caching, it's there for you.

0 commit comments

Comments
 (0)