当前位置: 首页>>代码示例>>PHP>>正文


PHP Kohana::output方法代码示例

本文整理汇总了PHP中Kohana::output方法的典型用法代码示例。如果您正苦于以下问题:PHP Kohana::output方法的具体用法?PHP Kohana::output怎么用?PHP Kohana::output使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Kohana的用法示例。


在下文中一共展示了Kohana::output方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: render

 public function render()
 {
     if (Kohana::config('core.render_stats') === TRUE) {
         // Replace the global template variables
         Kohana::$output = str_replace(array('{hanami_version}', '{hanami_codename}'), array(HANAMI_VERSION, HANAMI_CODENAME), Kohana::$output);
     }
 }
开发者ID:nicka1711,项目名称:hanami,代码行数:7,代码来源:hanami.php

示例2: output_buffer

 /**
  * Kohana output handler.
  *
  * @param   string  current output buffer
  * @return  string
  */
 public static function output_buffer($output)
 {
     if (!Event::has_run('system.send_headers')) {
         // Run the send_headers event, specifically for cookies being set
         Event::run('system.send_headers');
     }
     // Set final output
     self::$output = $output;
     // Set and return the final output
     return $output;
 }
开发者ID:nanangsyaifudin,项目名称:HAC-2012,代码行数:17,代码来源:Kohana.php

示例3: output_buffer

 /**
  * Kohana output handler. Called during ob_clean, ob_flush, and their variants.
  *
  * @param   string  current output buffer
  * @return  string
  */
 public static function output_buffer($output)
 {
     // Could be flushing, so send headers first
     if (!Event::has_run('system.send_headers')) {
         // Run the send_headers event
         Event::run('system.send_headers');
     }
     self::$output = $output;
     // Set and return the final output
     return self::$output;
 }
开发者ID:palie,项目名称:IDA-Framework,代码行数:17,代码来源:Kohana.php

示例4: prevent_output

 /**
  * Prevent any output from being displayed. Executed during system.display.
  *
  * @return  void
  */
 public static function prevent_output()
 {
     Kohana::$output = '';
 }
开发者ID:Juuro,项目名称:Dreamapp-Website,代码行数:9,代码来源:expires.php

示例5: render

 /**
  * Render the profiler. Output is added to the bottom of the page by default.
  *
  * @param   boolean  return the output if TRUE
  * @return  void|string
  */
 public function render($return = FALSE)
 {
     $start = microtime(TRUE);
     $get = isset($_GET['profiler']) ? explode(',', $_GET['profiler']) : array();
     $this->show = empty($get) ? Kohana::config('profiler.show') : $get;
     Event::run('profiler.run', $this);
     $styles = '';
     foreach ($this->profiles as $profile) {
         $styles .= $profile->styles();
     }
     // Don't display if there's no profiles
     if (empty($this->profiles)) {
         return;
     }
     // Load the profiler view
     $data = array('profiles' => $this->profiles, 'styles' => $styles, 'execution_time' => microtime(TRUE) - $start);
     $view = new View('kohana_profiler', $data);
     // Return rendered view if $return is TRUE
     if ($return == TRUE) {
         return $view->render();
     }
     // Add profiler data to the output
     if (stripos(Kohana::$output, '</body>') !== FALSE) {
         // Closing body tag was found, insert the profiler data before it
         Kohana::$output = str_ireplace('</body>', $view->render() . '</body>', Kohana::$output);
     } else {
         // Append the profiler data to the output
         Kohana::$output .= $view->render();
     }
 }
开发者ID:nebogeo,项目名称:borrowed-scenery,代码行数:36,代码来源:Profiler.php


注:本文中的Kohana::output方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。