Opened 14 years ago
Closed 13 years ago
#4738 closed enhancement (invalid)
[autocomplete] Added configuration option for query parameter name.
Reported by: | dfd | Owned by: | |
---|---|---|---|
Priority: | minor | Milestone: | 1.4 |
Component: | unfiled | Version: | 1.3.2 |
Keywords: | autocomplete plugin | Cc: | |
Blocked by: | Blocking: |
Description
I needed this, so I added a few small changes to make it work. The plugin works the same as before, with 'q' as the default name of the search query variable passed to the server-side script, but I added a parameter that can be passed in as an option called 'queryParamName.'
So, for example, if I wanted to have my query param to be called 'title' vs. 'q,' I could change this like so:
$("input#document_title").autocomplete('/documents.js', { queryParamName: 'title'});
That's all there is to it. I'd love to get this included in the plugin if possible, and of course I'm not set on any of the naming conventions or coding style, I just want the functionality.
The diff I'm attaching is to version 1.0.2 I believe, as that's the last version mentioned in the changelog from the zip file I downloaded here: http://bassistance.de/jquery-plugins/jquery-plugin-autocomplete/.
Thanks!
Best, Dave
Attachments (2)
Change History (3)
Changed 14 years ago by
Attachment: | queryParamName.diff added |
---|
Changed 14 years ago by
Attachment: | jquery.autocomplete.js added |
---|
My modified jquery.autocomplete.js file.
comment:1 Changed 13 years ago by
Resolution: | → invalid |
---|---|
Status: | new → closed |
This is not a jQuery core bug. Please use the jQuery forums or contact the author via the method they request. For jQuery UI plugins, please file a bug on http://dev.jqueryui.com .
Simple diff file of original (v1.0.2 I believe) jquery.autocomplete.js and my updated version