Fyi is a simple prototype-based javascript plugin to show tooltips when a text_field has focus
./script/plugin install git://github.com/omenking/fyi.git
Go get em and place them in your public/javascripts
Add into your layout head
<%= javascript_include_tag ‘prototype’, ‘lowpro’, ‘fyi’ >
<= stylesheet_link_tag ‘fyi.css’ %>
<%= f.password_field :login >
<= tooltip ‘user_login’, ‘Type a short username all lowercase and use spaces for underscores’ %>
tooltip(name,html,options={})
- name – id of the tooltip (needs to be the id name of the text_field)
- html – the html you want to pass
If you have Sass or Sprockets installed it’ll copy them to their respected default directories.
Sass and Sprockets rule!
Remember to add to your app/javascripts/application.js
//= require
Remember to add to your application.sass
@import fyi.sass
Copyright © 2009 Andrew Brown, released under the MIT license