Revize 1400
Přidáno uživatelem David Raška před asi 12 roky(ů)
freenetis/branches/testing/system/core/Kohana.php | ||
---|---|---|
error_reporting($ER);
|
||
|
||
// Start output buffering (in PHP 5.4 is old code broken)
|
||
if (version_compare(PHP_VERSION, '5.4.0', '>='))
|
||
{
|
||
ob_start(array('Kohana', 'output_buffer'), 1);
|
||
}
|
||
else
|
||
{
|
||
ob_start(array('Kohana', 'output_buffer'));
|
||
}
|
||
ob_start(array('Kohana', 'output_buffer'));
|
||
|
||
// Save buffering level
|
||
self::$buffer_level = ob_get_level();
|
||
... | ... | |
// Flush all open output buffers above the internal buffer
|
||
ob_end_flush();
|
||
}
|
||
|
||
// This will flush the Kohana buffer, which sets self::$output
|
||
(ob_get_level() === self::$buffer_level) and ob_end_clean();
|
||
|
||
|
||
//Due to blank page issue in PHP 5.4, we have to save content of buffer before calling
|
||
//ob_end_clean()
|
||
$out = ob_get_contents();
|
||
|
||
ob_end_clean();
|
||
|
||
// Run the output event
|
||
Event::run('system.display', self::$output);
|
||
Event::run('system.display', $out);
|
||
|
||
// Render the final output
|
||
self::render(self::$output);
|
||
self::render($out);
|
||
|
||
// save logs
|
||
if (Config::get('log_threshold') > 0)
|
||
... | ... | |
header('Content-Length: '.strlen($output));
|
||
}
|
||
}
|
||
|
||
|
||
echo $output;
|
||
}
|
||
|
Také k dispozici: Unified diff
Opravy:
- #165: Opravena chyba v nahrazovani textu v paticce a chyba prazdne stranky v PHP 5.4