
Security News
Follow-up and Clarification on Recent Malicious Ruby Gems Campaign
A clarification on our recent research investigating 60 malicious Ruby gems.
idris-auto_complete_jquery
Advanced tools
This plugin provides a auto-complete method for your controllers to be used with Dylan Verheul's jquery autocomplete plugin. This jQuery plugin is not included, and can be obtained from:
http://bassistance.de/jquery-plugins/jquery-plugin-autocomplete/
This auto_complete_jquery plugin is just a modified version of the standard Rails auto_complete plugin. It provides the same auto_complete_for method for your controllers, but eliminates the various view helper methods, as those are not needed when using jQuery and Unobtrusive JavaScript.
To use this, you need to have jQuery and the autocomplete plugin mentioned above (as well as appropriate CSS). Then, there are four aspects of setting up an auto-complete field:
<%= post.text_field :title, :autocomplete =>"off" %>
<%= stylesheet_link_tag 'jquery.ui.autocomplete' %> <%= javascript_include_tag 'jquery.min', 'jquery.dimensions.min', 'jquery.templating', 'jquery.ui.autocomplete.ext', 'jquery.ui.autocomplete', :cache => 'jquery' %>
class BlogController < ApplicationController auto_complete_for :post, :title end
$(document).ready(function() { $("input#post_title").autocomplete("auto_complete_for_post_title") });
By default, auto_complete_for limits the results to 10 entries, and sorts by the given field.
auto_complete_for takes a third parameter, an options hash to the find method used to search for the records:
auto_complete_for :post, :title, :limit => 15, :order => 'created_at DESC'
For more information, see:
Copyright (c) 2008 Cobalt Edge LLC, released under the MIT license.
FAQs
Unknown package
We found that idris-auto_complete_jquery demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
A clarification on our recent research investigating 60 malicious Ruby gems.
Security News
ESLint now supports parallel linting with a new --concurrency flag, delivering major speed gains and closing a 10-year-old feature request.
Research
/Security News
A malicious Go module posing as an SSH brute forcer exfiltrates stolen credentials to a Telegram bot controlled by a Russian-speaking threat actor.