From 01f0d9562e5e177658ff956ba303fded61e0d3ba Mon Sep 17 00:00:00 2001 From: Igor Vaynberg Date: Tue, 14 May 2013 14:07:09 -0700 Subject: [PATCH] fixed typos. fixes #1309 --- index.html | 2 +- select2-latest.html | 2 +- select2-master | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/index.html b/index.html index 87df38dc..adac518f 100644 --- a/index.html +++ b/index.html @@ -1531,7 +1531,7 @@ $("#select").select2({

val method invoked on a single-select with an unset value will return "", while a val method invoked on an empty multi-select will return []

- Example:
alert("Selected value is: "+$("#e8").select2("val")); $("#e8").select2("val", "CA"});
+ Example:
alert("Selected value is: "+$("#e8").select2("val")); $("#e8").select2("val", "CA");

Notice that in order to use this method you must define the initSelection function in the options so Select2 knows how to transform the id of the object you pass in val() to the full object it needs to render selection. If you are attaching to a select element this function is already provided for you.

diff --git a/select2-latest.html b/select2-latest.html index d3ced215..ff28d655 100644 --- a/select2-latest.html +++ b/select2-latest.html @@ -1542,7 +1542,7 @@ $("#select").select2({

val method invoked on a single-select with an unset value will return "", while a val method invoked on an empty multi-select will return []

- Example:
alert("Selected value is: "+$("#e8").select2("val")); $("#e8").select2("val", "CA"});
+ Example:
alert("Selected value is: "+$("#e8").select2("val")); $("#e8").select2("val", "CA");

Notice that in order to use this method you must define the initSelection function in the options so Select2 knows how to transform the id of the object you pass in val() to the full object it needs to render selection. If you are attaching to a select element this function is already provided for you.

diff --git a/select2-master b/select2-master index 95d3728b..de6d90c0 160000 --- a/select2-master +++ b/select2-master @@ -1 +1 @@ -Subproject commit 95d3728b77c0e3adcbeaab0b9e5a6b77b67e23c0 +Subproject commit de6d90c079803659e1c30c54d093c64e8259b0f2