aboutsummaryrefslogtreecommitdiffstats
path: root/railties/html/javascripts/controls.js
diff options
context:
space:
mode:
authorThomas Fuchs <thomas@fesch.at>2006-11-19 23:01:32 +0000
committerThomas Fuchs <thomas@fesch.at>2006-11-19 23:01:32 +0000
commitde6ffba80673543d39ec7ef851fe9d1f7ab3a148 (patch)
tree211e3f5b075c5b0a244d74783c5bdc4a18e04205 /railties/html/javascripts/controls.js
parent44de099efe35a51b709ae754d8c5f769da2bc753 (diff)
downloadrails-de6ffba80673543d39ec7ef851fe9d1f7ab3a148.tar.gz
rails-de6ffba80673543d39ec7ef851fe9d1f7ab3a148.tar.bz2
rails-de6ffba80673543d39ec7ef851fe9d1f7ab3a148.zip
Update trunk w/ latest Prototype and script.aculo.us
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@5581 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
Diffstat (limited to 'railties/html/javascripts/controls.js')
-rw-r--r--railties/html/javascripts/controls.js11
1 files changed, 6 insertions, 5 deletions
diff --git a/railties/html/javascripts/controls.js b/railties/html/javascripts/controls.js
index c81b25c757..8c273f874f 100644
--- a/railties/html/javascripts/controls.js
+++ b/railties/html/javascripts/controls.js
@@ -1,6 +1,6 @@
-// Copyright (c) 2005 Thomas Fuchs (http://script.aculo.us, http://mir.aculo.us)
-// (c) 2005 Ivan Krstic (http://blogs.law.harvard.edu/ivan)
-// (c) 2005 Jon Tirsen (http://www.tirsen.com)
+// Copyright (c) 2005, 2006 Thomas Fuchs (http://script.aculo.us, http://mir.aculo.us)
+// (c) 2005, 2006 Ivan Krstic (http://blogs.law.harvard.edu/ivan)
+// (c) 2005, 2006 Jon Tirsen (http://www.tirsen.com)
// Contributors:
// Richard Livsey
// Rahul Bhargava
@@ -473,6 +473,7 @@ Ajax.InPlaceEditor.prototype = {
this.element = $(element);
this.options = Object.extend({
+ paramName: "value",
okButton: true,
okText: "ok",
cancelLink: true,
@@ -604,7 +605,7 @@ Ajax.InPlaceEditor.prototype = {
var textField = document.createElement("input");
textField.obj = this;
textField.type = "text";
- textField.name = "value";
+ textField.name = this.options.paramName;
textField.value = text;
textField.style.backgroundColor = this.options.highlightcolor;
textField.className = 'editor_field';
@@ -617,7 +618,7 @@ Ajax.InPlaceEditor.prototype = {
this.options.textarea = true;
var textArea = document.createElement("textarea");
textArea.obj = this;
- textArea.name = "value";
+ textArea.name = this.options.paramName;
textArea.value = this.convertHTMLLineBreaks(text);
textArea.rows = this.options.rows;
textArea.cols = this.options.cols || 40;