當前位置: 首頁>>代碼示例>>PHP>>正文


PHP Controller::after方法代碼示例

本文整理匯總了PHP中Controller::after方法的典型用法代碼示例。如果您正苦於以下問題:PHP Controller::after方法的具體用法?PHP Controller::after怎麽用?PHP Controller::after使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在Controller的用法示例。


在下文中一共展示了Controller::after方法的15個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。

示例1: after

 /**
  * Assigns the template [View] as the request response.
  */
 public function after()
 {
     if ($this->_autoRender === TRUE) {
         $this->response->body($this->_default->render());
     }
     parent::after();
 }
開發者ID:panchao1,項目名稱:cronsystem,代碼行數:10,代碼來源:Template.php

示例2: after

 /**
  * The after() method is called after controller action
  *
  * @uses  Request::is_ajax
  * @uses  Response::headers
  */
 public function after()
 {
     if ($this->request->is_ajax()) {
         $this->response->headers('content-type', 'application/json; charset=' . Kohana::$charset);
     }
     parent::after();
 }
開發者ID:MenZil-Team,項目名稱:cms,代碼行數:13,代碼來源:autocomplete.php

示例3: after

 /**
  * If auto_render is enabled and no response has yet been sent, selects
  * a content view based on the controller and action name, and then 
  * returns the template as the request response.
  * 
  * @return  void
  */
 public function after()
 {
     if ($this->auto_render === TRUE and !$this->request->response) {
         $this->render();
     }
     parent::after();
 }
開發者ID:evansd-archive,項目名稱:kohana3-module--utilities,代碼行數:14,代碼來源:layout.php

示例4: after

 public function after()
 {
     if ($this->template !== NULL) {
         $this->request->body($this->template->render());
     }
     return parent::after();
 }
開發者ID:nergal,項目名稱:kohana-libs,代碼行數:7,代碼來源:abstract.php

示例5: after

 public function after()
 {
     parent::after();
     if ($this->auto_render !== TRUE) {
         $this->request->response = (string) $this->content;
     }
 }
開發者ID:andygoo,項目名稱:kohana,代碼行數:7,代碼來源:Devtools.php

示例6: after

 /**
  * Assigns the template [View] as the request response.
  */
 public function after()
 {
     if ($this->auto_render === true) {
         $this->response->body($this->template->render());
     }
     parent::after();
 }
開發者ID:s4urp8n,項目名稱:kohana-admin,代碼行數:10,代碼來源:Template.php

示例7: after

 /**
  * Assigns the template [View] as the request response.
  */
 public function after()
 {
     if ($this->auto_render === TRUE) {
         $this->request->response = $this->template;
     }
     return parent::after();
 }
開發者ID:abdul-baten,項目名稱:hbcms,代碼行數:10,代碼來源:template.php

示例8: after

 public function after()
 {
     if ($this->auto_render === TRUE) {
         $this->response->body($this->template->render());
     }
     return parent::after();
 }
開發者ID:slumbersoul,項目名稱:gnw-weixin,代碼行數:7,代碼來源:template.php

示例9: after

 /**
  * Handle Request Data persistence or output based on the request type.
  */
 public function after()
 {
     if ($this->_handle_ajax == true) {
         if ($this->request->is_ajax()) {
             $return = array();
             if (RD::has_messages() == false) {
                 $return['status'] = 'success';
                 $return['response'] = [''];
             } else {
                 if (RD::get_current(RD::ERROR) != null) {
                     $return['status'] = 'error';
                     $return['errors'] = RD::get_current(RD::ERROR);
                 } else {
                     if (RD::get_current(array(RD::SUCCESS, RD::INFO)) != null) {
                         $return['status'] = 'success';
                         $return['response'] = RD::get_current(array(RD::SUCCESS, RD::INFO, RD::WARNING));
                     } else {
                         $return['status'] = 'success';
                         $return['response'] = RD::get_current();
                     }
                 }
             }
             $this->response->headers('Content-Type', 'application/json');
             $this->response->body(json_encode($return));
         } else {
             //otherwise flash the messages so they can be used on the next page load
             if (RD::has_messages()) {
                 RD::persist();
             }
             parent::after();
         }
     } else {
         parent::after();
     }
 }
開發者ID:happydemon,項目名稱:req,代碼行數:38,代碼來源:Req.php

示例10: after

 /**
  * Assigns the content [View] as the request response.
  */
 public function after()
 {
     if ($this->_view instanceof View) {
         $this->response->body($this->_view->render());
     }
     parent::after();
 }
開發者ID:nguyennv,項目名稱:kohana-common,代碼行數:10,代碼來源:base.php

示例11: after

 public function after()
 {
     parent::after();
     if ($this->auto_render === TRUE) {
         $this->response->body($this->view->render());
     }
 }
開發者ID:Hinton,項目名稱:langify,代碼行數:7,代碼來源:base.php

示例12: after

 public function after()
 {
     if ($this->auto_render) {
         Jx_Event::post($this, 'beforeRender', $this->template);
         $this->request->response = $this->template;
     }
     return parent::after();
 }
開發者ID:jonlb,項目名稱:JxCMS,代碼行數:8,代碼來源:site.php

示例13: after

 public function after()
 {
     parent::after();
     if ($this->cache === TRUE && $this->request->status === 200 && $this->session->user->manage_dash_mods === null) {
         $cache = new Cache($this->cache_config);
         $cache->set($this->request->uri . ' :: ' . $this->session->group, $this->request->response, $this->cache_tag, $this->cache_lifetime);
     }
 }
開發者ID:pedrosland,項目名稱:kohana-cache,代碼行數:8,代碼來源:controller.php

示例14: after

 public function after()
 {
     parent::after();
     $handle = $this->server->handle();
     if (Request::is_amf()) {
         $this->response->body($handle);
     }
 }
開發者ID:elrolito,項目名稱:zendamf-for-kohana,代碼行數:8,代碼來源:amf.php

示例15: after

 public function after()
 {
     $this->view->controller = $this->getRequest()->getController();
     $this->view->action = $this->getRequest()->getAction();
     $this->view->template = str_replace(DOC_ROOT, '', $this->view->getView());
     // Load parent::after to render this controller.
     parent::after();
 }
開發者ID:atlas1308,項目名稱:testtesttestfarm,代碼行數:8,代碼來源:render.php


注:本文中的Controller::after方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。