From 875473e8d17550ac7bf9ec26e497986586401467 Mon Sep 17 00:00:00 2001 From: Christian Seel Date: Fri, 3 Oct 2014 16:21:11 +0200 Subject: [PATCH] allow data manipulation This adds the possibility to manipulate the data that is returned from the ajax request in the custom success handler. --- js/foundation/foundation.reveal.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/js/foundation/foundation.reveal.js b/js/foundation/foundation.reveal.js index ab7efefa1..9836abc57 100644 --- a/js/foundation/foundation.reveal.js +++ b/js/foundation/foundation.reveal.js @@ -193,7 +193,8 @@ $.extend(ajax_settings, { success: function (data, textStatus, jqXHR) { if ( $.isFunction(old_success) ) { - old_success(data, textStatus, jqXHR); + var result = old_success(data, textStatus, jqXHR); + if (typeof result == 'string') data = result; } modal.html(data); -- 2.47.2