You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@felix.apache.org by fm...@apache.org on 2010/03/13 15:23:50 UTC

svn commit: r922575 - /felix/trunk/webconsole/src/main/resources/res/lib/support.js

Author: fmeschbe
Date: Sat Mar 13 14:23:50 2010
New Revision: 922575

URL: http://svn.apache.org/viewvc?rev=922575&view=rev
Log:
FELIX-2183 Apply supportjs-ajax-error.patch by Valentin Valchev (thanks)

Modified:
    felix/trunk/webconsole/src/main/resources/res/lib/support.js

Modified: felix/trunk/webconsole/src/main/resources/res/lib/support.js
URL: http://svn.apache.org/viewvc/felix/trunk/webconsole/src/main/resources/res/lib/support.js?rev=922575&r1=922574&r2=922575&view=diff
==============================================================================
--- felix/trunk/webconsole/src/main/resources/res/lib/support.js (original)
+++ felix/trunk/webconsole/src/main/resources/res/lib/support.js Sat Mar 13 14:23:50 2010
@@ -71,7 +71,9 @@ $(document).ready(function() {
 
 	// register global ajax error handler
 	$(document).ajaxError( function(event, req) {
-		Xalert('The request failed: <br/><pre>' + req.statusText + '</pre>', 'AJAX Error');
+		var text = req.responseXML ? x = req.responseXML :
+				(req.responseText ? x = req.responseText : req.statusText);
+		Xalert('The request failed: <br/><pre>' + text + '</pre>', 'AJAX Error');
 	});
 
 	initStaticWidgets();