From a5dcd9292c35de0a4f84204e5ccda4ed77173a7d Mon Sep 17 00:00:00 2001 From: Anchor Date: Mon, 26 Jan 2015 21:22:32 -0800 Subject: [PATCH] Finalize translation fixes for 13.3.md --- en/13.3.md | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/en/13.3.md b/en/13.3.md index a00a2b20..2b01eab0 100644 --- a/en/13.3.md +++ b/en/13.3.md @@ -125,7 +125,7 @@ Above, the controller base class already implements the functions defined in the ## Application guide -Above beego Framework base class to complete the design of the controller, then we in our application can be to design our approach: +Above, we've just finished discussing Beego's implementation of the base controller class. We can now use this information to design our request handling, inheriting from the base class and implementing the necessary methods in our own controller. package controllers @@ -143,11 +143,11 @@ Above beego Framework base class to complete the design of the controller, then this.TplNames = "index.tpl" } -The way we achieved above subclass MainController, implements Get method, so if the user through other means(POST/HEAD, etc. ) to access the resource will return 403, and if it is Get access, because we set the AutoRender = true, then play in the implementation of the Get method is performed automatically after the Render function, it will display the following interface: +In the code above, we've implemented a subclass of `Controller` called `MainController` which only implements the `Get()` method. If a user tries to access the resource using any of the other HTTP methods (POST, HEAD, etc), a 403 Forbidden will be returned. However, if a user submits a GET request to the resource and we have have the `AutoRender` variable set to `true`, the resource's controller will automatically call its `Render()` function, rendering the corresponding template and responding with the following: ![](images/13.4.beego.png?raw=true) -index.tpl code is shown below, we can see the data set and display are quite simple: +The `index.tpl` code can be seen below; as you can see, parsing model data into a template is quite simple: @@ -163,5 +163,5 @@ index.tpl code is shown below, we can see the data set and display are quite sim ## Links - [Directory](preface.md) -- Previous section: [Customized routers](13.2.md) +- Previous section: [Customizing routers](13.2.md) - Next section: [Logs and configurations](13.4.md)