From bbefc33c9c3fd025ee768f8480578128ba30a8da Mon Sep 17 00:00:00 2001 From: Larry Ullman Date: Fri, 25 Apr 2014 20:16:47 -0400 Subject: [PATCH] Edited Introduction Cut a sentence that seemed both redundant and vague. Could just be me. --- docs/guide/events.md | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/docs/guide/events.md b/docs/guide/events.md index 1d240e6fd7..635f67c623 100644 --- a/docs/guide/events.md +++ b/docs/guide/events.md @@ -1,11 +1,10 @@ Events ====== -Event is a way to "inject" custom code into existing code at certain places. For example, a comment object can trigger -an "add" event when the user adds a comment. We can write custom code and attach it to this event so that when the event -is triggered (i.e. comment will be added), our custom code will be executed. +Yii uses events to "inject" custom code into existing code at certain execution points. For example, a comment object can trigger +an "add" event when the user adds a comment to a post. -Events are very useful both to make your components flexible and to hook into framework and extensions workflow. +Events are very useful for two reasons. First, they can make your components more flexible. Second, you can hook your own code into the regular workflow of both the framework and the extensions in use. Triggering events -----------------