I've implemented part of this script to help me with debugging
var ZFDebugLoad = window.onload;
window.onload = function(){
if (ZFDebugLoad) {
ZFDebugLoad();
}
ZFDebugCollapsed();
};
Firebug gives me the error "break on Error too much recursion"
The code to me looks like an endless loop so I'm wondering why the original author put it in. Also there's no return in the function, so ZFDebugLoad would never have a value...
EDIT The actual cause for this error (for any other people that followed the same tutorial I did, the cause to the error was this line
$response->setBody(preg_replace('/(<head.*>)/i', '$1' . $this->_headerOutput(), $response->getBody()));
which uses the regex pattern /(<head.*>)/i
, this caused the script to be appended into my HTML5 <header>
tag, t correct this I inserted a space into the pattern /<head(?!er).*?>/i