Socket
Book a DemoInstallSign in
Socket

freefind_rails

Package Overview
Dependencies
Maintainers
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

freefind_rails

bundlerRubygems
Version
0.1.2
Version published
Maintainers
1
Created
Source

Freefind Rails

Easy way to use freefind.com search service in your Rails app. You need to create an account at freefind.com first.

Installation

Add this line to your application's Gemfile:

gem 'freefind_rails'

And then execute:

$ bundle

Or install it yourself as:

$ gem install freefind_rails

Include the javascript into the asset pipeline: /app/assets/javascripts/application.js

//= require freefind

Usage

Add the _freefind_search.html.haml view partial where you want the search input box to appear

= render partial: '/freefind_search', locals: { freefind_site_id: your-id }

Make sure to pass your freefind site id into the partial as a local variable. This can be done in the parent application by hardcoding it directly or by using a Rails configuration file.

Add the _freefind_onpage_results.html.haml view partial to the same page if you want search results to populate into that same page instead of in a new page.

= render partial: '/freefind_onpage_results'

Contributing

  • Fork it ( https://github.com/[my-github-username]/freefind_rails/fork )
  • Create your feature branch (git checkout -b my-new-feature)
  • Commit your changes (git commit -am 'Add some feature')
  • Push to the branch (git push origin my-new-feature)
  • Create a new Pull Request

FAQs

Package last updated on 30 Mar 2015

Did you know?

Socket

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.

Install

Related posts