Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Removing controller dump and debug = 3 support from View. Controller …

…dumps often cause memory overflow errors, and are generally not useful.
  • Loading branch information...
commit 6efe61d9b20401d9bc7a497e33beb3d12cb55f5c 1 parent a89fcba
@markstory markstory authored
View
25 cake/libs/view/elements/dump.ctp
@@ -1,25 +0,0 @@
-<?php
-/**
- *
- * PHP versions 4 and 5
- *
- * CakePHP(tm) : Rapid Development Framework (http://cakephp.org)
- * Copyright 2005-2009, Cake Software Foundation, Inc. (http://cakefoundation.org)
- *
- * Licensed under The MIT License
- * Redistributions of files must retain the above copyright notice.
- *
- * @copyright Copyright 2005-2009, Cake Software Foundation, Inc. (http://cakefoundation.org)
- * @link http://cakephp.org CakePHP(tm) Project
- * @package cake
- * @subpackage cake.cake.libs.view.templates.elements
- * @since CakePHP(tm) v 0.10.5.1782
- * @license MIT License (http://www.opensource.org/licenses/mit-license.php)
- */
-?>
-<div id="cakeControllerDump">
- <h2><?php __('Controller dump:'); ?></h2>
- <pre>
- <?php echo h(print_r($controller, true)); ?>
- </pre>
-</div>
View
1  cake/libs/view/layouts/default.ctp
@@ -54,7 +54,6 @@
?>
</div>
</div>
- <?php echo $cakeDebug; ?>
<?php echo $this->element('sql_dump'); ?>
</body>
</html>
View
10 cake/libs/view/view.php
@@ -433,7 +433,6 @@ function render($action = null, $layout = null, $file = null) {
* - `title_for_layout` - contains page title
* - `content_for_layout` - contains rendered view file
* - `scripts_for_layout` - contains scripts added to header
- * - `cakeDebug` - if debug is on, cake debug information is added.
*
* @param string $content_for_layout Content to render in a view, wrapped by the surrounding layout.
* @return mixed Rendered output, or false on error
@@ -444,18 +443,9 @@ function renderLayout($content_for_layout, $layout = null) {
return $this->output;
}
- $debug = '';
-
- if (isset($this->viewVars['cakeDebug']) && Configure::read() > 2) {
- $params = array('controller' => $this->viewVars['cakeDebug']);
- $debug = View::element('dump', $params, false);
- unset($this->viewVars['cakeDebug']);
- }
-
$dataForLayout = array_merge($this->viewVars, array(
'content_for_layout' => $content_for_layout,
'scripts_for_layout' => implode("\n\t", $this->__scripts),
- 'cakeDebug' => $debug
));
if (!isset($dataForLayout['title_for_layout'])) {
Please sign in to comment.
Something went wrong with that request. Please try again.