Added features and bug fixes

Max's Avatar


15 Jun, 2011 01:57 PM

Thank you for a beautiful plugin. However, I noticed a bug and also two missing features.
I find it strange that no one else has noticed the bug before. Either way, I attach my edited file and hope it will be of use to you!

The bug: It seems that even if the user removes all items (pressing backspace repeatedly for example), the hidden input field still keeps the id one item. This is because of how the code tries to match for example ",12," in the value_input. This does of course not match the left-most value. I fixed this by prefixing the value with "," before doing the matching.

Feature 1 - Option: Not allowing free text items: I added an option called "allowFreeText" which, if set to false, forces the user to choose an item from the list. I.e. the user can not type "alksnfklasnfl" and press tab.

Feature 2 - Option: Select first item: I also added an option call "selectFirst" which, if set to true, automatically selects the first item that is matched. This makes it much faster to input many items.

Other than this, the plugin is excellent.


  1. 1 Posted by Dario on 23 Jun, 2011 03:47 PM

    Dario's Avatar


    I also noticed this bug I found strange that nobody noticed it.

    Thanks a lot for your bug fix, really appreciated!

Reply to this discussion

Internal reply

Formatting help / Preview (switch to plain text) No formatting (switch to Markdown)

Attaching KB article:


Already uploaded files

  • jquery.autoSuggest.max.js 13.5 KB

Attached Files

You can attach files up to 10MB

If you don't have an account yet, we need to confirm you're human and not a machine trying to post spam.

Keyboard shortcuts


? Show this help
ESC Blurs the current field

Comment Form

r Focus the comment reply box
^ + ↩ Submit the comment

You can use Command ⌘ instead of Control ^ on Mac