Index: branches/5.3.x/core/kernel/utility/debugger.php =================================================================== diff -u -N -r16195 -r16221 --- branches/5.3.x/core/kernel/utility/debugger.php (.../debugger.php) (revision 16195) +++ branches/5.3.x/core/kernel/utility/debugger.php (.../debugger.php) (revision 16221) @@ -1,6 +1,6 @@ '', 'params' => array()); + + /** * Creates instance of debugger */ public function __construct() @@ -489,9 +496,27 @@ foreach ($dbg_constMap as $dbg_constName => $dbg_constValue) { DebuggerUtil::safeDefine($dbg_constName, $dbg_constValue); } + + $this->parseEditorUrl(); } /** + * Parses editor url. + * + * @return void + */ + protected function parseEditorUrl() + { + $components = parse_url(DBG_EDITOR_URL); + + $this->editorUrlData['url'] = $components['scheme'] . '://' . $components['host'] . $components['path']; + + if ( isset($components['query']) ) { + parse_str(html_entity_decode($components['query']), $this->editorUrlData['params']); + } + } + + /** * Performs debugger initialization * * @return void @@ -986,9 +1011,19 @@ $title = str_replace('/', '\\', $this->getLocalFile($file)); } - $url = str_replace('%F', $this->getLocalFile($file), DBG_EDITOR_URL); - $url = str_replace('%L', $line_number, $url); + $local_file = $this->getLocalFile($file); + $url_params = $this->editorUrlData['params']; + foreach ( $url_params as $param_name => $param_value ) { + $url_params[$param_name] = str_replace( + array('%F', '%L'), + array($local_file, $line_number), + $param_value + ); + } + + $url = $this->editorUrlData['url'] . '?' . http_build_query($url_params); + return '' . $title . ''; } @@ -2086,4 +2121,4 @@ if ( DebuggerUtil::constOn('DBG_USE_SHUTDOWN_FUNC') ) { register_shutdown_function(array(&$debugger, 'printReport'), false, true, true); } - } \ No newline at end of file + }