From 62e0ae600476bc3611b342b4d0b7686e5d210cc5 Mon Sep 17 00:00:00 2001 From: Igor Vaynberg Date: Mon, 6 May 2013 09:54:17 -0700 Subject: [PATCH] #1260 closes #1252 fixes #992 - retrieve option text as value when value is not defined --- component.json | 2 +- select2.jquery.json | 2 +- select2.js | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/component.json b/component.json index 302cf22d..e95c29b7 100644 --- a/component.json +++ b/component.json @@ -3,6 +3,6 @@ "version": "3.3.2", "main": ["select2.js", "select2.css", "select2.png", "select2x2.png", "select2-spinner.gif"], "dependencies": { - "jquery": ">= 1.4.4" + "jquery": ">= 1.7.1" } } diff --git a/select2.jquery.json b/select2.jquery.json index f541a4d5..821242ba 100644 --- a/select2.jquery.json +++ b/select2.jquery.json @@ -31,6 +31,6 @@ "docs": "http://ivaynberg.github.com/select2/", "download": "https://github.com/ivaynberg/select2/tags", "dependencies": { - "jquery": ">=1.4.4" + "jquery": ">=1.7.1" } } diff --git a/select2.js b/select2.js index 54c7dd73..e4d666a6 100644 --- a/select2.js +++ b/select2.js @@ -739,7 +739,7 @@ the specific language governing permissions and limitations under the Apache Lic optionToData: function(element) { if (element.is("option")) { return { - id:element.attr("value"), + id:element.prop("value"), text:element.text(), element: element.get(), css: element.attr("class"),