PHP 클래스 CI_Output, TastyIgniter

Responsible for sending final output to browser
저자: EllisLab Dev Team
파일 보기 프로젝트 열기: tastyigniter/tastyigniter 1 사용 예제들

공개 프로퍼티들

프로퍼티 타입 설명
$cache_expiration integer Cache expiration time
$enable_profiler boolean Enable Profiler flag
$final_output string Final output string
$headers array List of server headers
$mimes array List of mime types
$parse_exec_vars boolean Whether or not to parse variables like {elapsed_time} and {memory_usage}.

보호된 프로퍼티들

프로퍼티 타입 설명
$_compress_output boolean CI output compression flag
$_profiler_sections array List of profiler sections
$_zlib_oc boolean php.ini zlib.output_compression flag
$mime_type string Mime-type for the current page

공개 메소드들

메소드 설명
__construct ( ) : void Class constructor
_display ( string $output = '' ) : void Display Output
_display_cache ( &$CFG, &$URI ) : boolean Update/serve cached output
_write_cache ( string $output ) : void Write Cache
append_output ( string $output ) : CI_Output Append Output
cache ( integer $time ) : CI_Output Set Cache
delete_cache ( string $uri = '' ) : boolean Delete cache
enable_profiler ( boolean $val = TRUE ) : CI_Output Enable/disable Profiler
get_content_type ( ) : string Get Current Content-Type Header
get_header ( $header ) : string Get Header
get_output ( ) : string Get Output
set_cache_header ( integer $last_modified, integer $expiration ) : void Set Cache Header
set_content_type ( string $mime_type, string $charset = NULL ) : CI_Output Set Content-Type Header
set_header ( string $header, boolean $replace = TRUE ) : CI_Output Set Header
set_output ( string $output ) : CI_Output Set Output
set_profiler_sections ( array $sections ) : CI_Output Set Profiler Sections
set_status_header ( integer $code = 200, string $text = '' ) : CI_Output Set HTTP Status Header

메소드 상세

__construct() 공개 메소드

Determines whether zLib output compression will be used.
public __construct ( ) : void
리턴 void

_display() 공개 메소드

Processes and sends finalized output data to the browser along with any server headers and profile data. It also stops benchmark timers so the page rendering speed and memory usage can be shown. Note: All "view" data is automatically put into $this->final_output by controller class.
public _display ( string $output = '' ) : void
$output string Output data override
리턴 void

_display_cache() 공개 메소드

Update/serve cached output
public _display_cache ( &$CFG, &$URI ) : boolean
리턴 boolean TRUE on success or FALSE on failure

_write_cache() 공개 메소드

Write Cache
public _write_cache ( string $output ) : void
$output string Output data to cache
리턴 void

append_output() 공개 메소드

Appends data onto the output string.
public append_output ( string $output ) : CI_Output
$output string Data to append
리턴 CI_Output

cache() 공개 메소드

Set Cache
public cache ( integer $time ) : CI_Output
$time integer Cache expiration time in minutes
리턴 CI_Output

delete_cache() 공개 메소드

Delete cache
public delete_cache ( string $uri = '' ) : boolean
$uri string URI string
리턴 boolean

enable_profiler() 공개 메소드

Enable/disable Profiler
public enable_profiler ( boolean $val = TRUE ) : CI_Output
$val boolean TRUE to enable or FALSE to disable
리턴 CI_Output

get_content_type() 공개 메소드

Get Current Content-Type Header
public get_content_type ( ) : string
리턴 string 'text/html', if not already set

get_header() 공개 메소드

Get Header
public get_header ( $header ) : string
리턴 string

get_output() 공개 메소드

Returns the current output string.
public get_output ( ) : string
리턴 string

set_cache_header() 공개 메소드

Set the HTTP headers to match the server-side file cache settings in order to reduce bandwidth.
public set_cache_header ( integer $last_modified, integer $expiration ) : void
$last_modified integer Timestamp of when the page was last modified
$expiration integer Timestamp of when should the requested page expire from cache
리턴 void

set_content_type() 공개 메소드

Set Content-Type Header
public set_content_type ( string $mime_type, string $charset = NULL ) : CI_Output
$mime_type string Extension of the file we're outputting
$charset string Character set (default: NULL)
리턴 CI_Output

set_header() 공개 메소드

Lets you set a server header which will be sent with the final output. Note: If a file is cached, headers will not be sent.
public set_header ( string $header, boolean $replace = TRUE ) : CI_Output
$header string Header
$replace boolean Whether to replace the old header value, if already set
리턴 CI_Output

set_output() 공개 메소드

Sets the output string.
public set_output ( string $output ) : CI_Output
$output string Output data
리턴 CI_Output

set_profiler_sections() 공개 메소드

Allows override of default/config settings for Profiler section display.
public set_profiler_sections ( array $sections ) : CI_Output
$sections array Profiler sections
리턴 CI_Output

set_status_header() 공개 메소드

As of version 1.7.2, this is an alias for common function set_status_header().
public set_status_header ( integer $code = 200, string $text = '' ) : CI_Output
$code integer Status code (default: 200)
$text string Optional message
리턴 CI_Output

프로퍼티 상세

$_compress_output 보호되어 있는 프로퍼티

CI output compression flag
protected bool $_compress_output
리턴 boolean

$_profiler_sections 보호되어 있는 프로퍼티

List of profiler sections
protected array $_profiler_sections
리턴 array

$_zlib_oc 보호되어 있는 프로퍼티

php.ini zlib.output_compression flag
protected bool $_zlib_oc
리턴 boolean

$cache_expiration 공개적으로 프로퍼티

Cache expiration time
public int $cache_expiration
리턴 integer

$enable_profiler 공개적으로 프로퍼티

Enable Profiler flag
public bool $enable_profiler
리턴 boolean

$final_output 공개적으로 프로퍼티

Final output string
public string $final_output
리턴 string

$headers 공개적으로 프로퍼티

List of server headers
public array $headers
리턴 array

$mime_type 보호되어 있는 프로퍼티

Mime-type for the current page
protected string $mime_type
리턴 string

$mimes 공개적으로 프로퍼티

List of mime types
public array $mimes
리턴 array

$parse_exec_vars 공개적으로 프로퍼티

Whether or not to parse variables like {elapsed_time} and {memory_usage}.
public bool $parse_exec_vars
리턴 boolean