Skip to content

Commit

Permalink
BUGFIX Force referer via "BackURL" POST data in CMS to work around IE…
Browse files Browse the repository at this point in the history
… problems with sending the base URL as the referer instead of the actual one (#7002)
  • Loading branch information
chillu committed Mar 30, 2012
1 parent 1091c7b commit 6c91aa0
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions admin/javascript/LeftAndMain.Content.js
Expand Up @@ -142,6 +142,11 @@
var formData = form.serializeArray();
// add button action
formData.push({name: $(button).attr('name'), value:'1'});
// Artificial HTTP referer, IE doesn't submit them via ajax.
// Also rewrites anchors to their page counterparts, which is important
// as automatic browser ajax response redirects seem to discard the hash/fragment.
formData.push({name: 'BackURL', value:History.getPageUrl()});

jQuery.ajax(jQuery.extend({
url: form.attr('action'),
data: formData,
Expand Down

0 comments on commit 6c91aa0

Please sign in to comment.