aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDavid Heinemeier Hansson <david@loudthinking.com>2006-03-12 06:04:03 +0000
committerDavid Heinemeier Hansson <david@loudthinking.com>2006-03-12 06:04:03 +0000
commit3a90c31a566ec3a818e5cc8f0c2dca58ad305c27 (patch)
tree9e8a566bae80ced3c3480b8323f9f80f2060bf7e
parent7af12d04cebe3a1ffcf55cae967d22fc7b0606c8 (diff)
downloadrails-3a90c31a566ec3a818e5cc8f0c2dca58ad305c27.tar.gz
rails-3a90c31a566ec3a818e5cc8f0c2dca58ad305c27.tar.bz2
rails-3a90c31a566ec3a818e5cc8f0c2dca58ad305c27.zip
Use accept headers
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@3845 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
-rw-r--r--railties/html/javascripts/prototype.js3
1 files changed, 2 insertions, 1 deletions
diff --git a/railties/html/javascripts/prototype.js b/railties/html/javascripts/prototype.js
index c528a4956d..5093f40189 100644
--- a/railties/html/javascripts/prototype.js
+++ b/railties/html/javascripts/prototype.js
@@ -703,7 +703,8 @@ Ajax.Request.prototype = Object.extend(new Ajax.Base(), {
setRequestHeaders: function() {
var requestHeaders =
['X-Requested-With', 'XMLHttpRequest',
- 'X-Prototype-Version', Prototype.Version];
+ 'X-Prototype-Version', Prototype.Version,
+ 'Accept', 'text/javascript; text/html; text/xml; */*' ];
if (this.options.method == 'post') {
requestHeaders.push('Content-type',