projects
/
roojs1
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
support cdata wrappers on enclosed html return
[roojs1]
/
Roo
/
form
/
Action.js
diff --git
a/Roo/form/Action.js
b/Roo/form/Action.js
index
b7ea9e7
..
febdb1d
100644
(file)
--- a/
Roo/form/Action.js
+++ b/
Roo/form/Action.js
@@
-8,7
+8,9
@@
* Fork - LGPL
* <script type="text/javascript">
*/
* Fork - LGPL
* <script type="text/javascript">
*/
-
+
+// as we use this in bootstrap.
+Roo.namespace('Roo.form');
/**
* @class Roo.form.Action
* Internal Class used to handle form actions
/**
* @class Roo.form.Action
* Internal Class used to handle form actions
@@
-17,7
+19,6
@@
* @param {Object} config Configuration options
*/
* @param {Object} config Configuration options
*/
-Roo.namespace('Roo.form');
// define the action interface
// define the action interface
@@
-225,7
+226,8
@@
Roo.extend(Roo.form.Action.Submit, Roo.form.Action, {
url:this.getUrl(!isPost),
method: method,
params:isPost ? this.getParams() : null,
url:this.getUrl(!isPost),
method: method,
params:isPost ? this.getParams() : null,
- isUpload: this.form.fileUpload
+ isUpload: this.form.fileUpload,
+ formData : this.form.formData
}));
this.uploadProgress();
}));
this.uploadProgress();
@@
-287,7
+289,13
@@
Roo.extend(Roo.form.Action.Submit, Roo.form.Action, {
}
var ret = false;
try {
}
var ret = false;
try {
- ret = Roo.decode(response.responseText);
+ var rt = response.responseText;
+ if (rt.match(/^\<!--\[CDATA\[/)) {
+ rt = rt.replace(/^\<!--\[CDATA\[/,'');
+ rt = rt.replace(/\]\]--\>$/,'');
+ }
+
+ ret = Roo.decode(rt);
} catch (e) {
ret = {
success: false,
} catch (e) {
ret = {
success: false,