Skip to content

Commit

Permalink
Omit quotation mark in the beginning when looking up tags
Browse files Browse the repository at this point in the history
  • Loading branch information
boamaod committed Jun 16, 2012
1 parent ed59596 commit 6b367ff
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion plugins/Tagging/jquery.tokeninput.js
Expand Up @@ -190,7 +190,7 @@ $.TokenList = function (input, settings) {
(val.charAt(0) == '"' && event.keyCode == KEY.QUOTE)) {
if(event.keyCode == KEY.QUOTE) { // close quotation marks
val=val.replace('"', ''); // remove quotation marks
val=val.replace(' ', ' '); // replace space with nonbr space
val=val.replace(' ', ' '); // replace space with nonbr space
}
if (selected_dropdown_item) {
add_token($(selected_dropdown_item));
Expand Down Expand Up @@ -563,6 +563,8 @@ $.TokenList = function (input, settings) {
// than settings.minChars
function do_search(immediate) {
var query = input_box.val().toLowerCase();
if (query.charAt(0) == '"')
query = query.substr(1);

if (query && query.length) {
if(selected_token) {
Expand Down

0 comments on commit 6b367ff

Please sign in to comment.