![]() |
# File: README [ "plugins/live_validation/README", "plugins/live_validation/INSTALL", "plugins/live_validation/LICENCE", "plugins/live_validation/lib/live_validation/view_helpers.rb", nil].each do LiveValidation.view_html LiveValidation::ViewHelpers.view_html end |
Copyright (c) 2008 Gregoire Lejeune. All rights reserved.
live_validation is a Bivouac plugin using LiveValidation
ruby script/plugin install live_validation rake plugin:live_validation:install
In the layout :
javascript_include_tag :defaults
javascript_include_tag "livevalidation"
stylesheet_link_tag "livevalidation"
In the view :
input :type => "text", :id => "f1"
live_validation "f1", :validMessage => "Hey there!", :wait => 500 do
validate_presence :failureMessage => "Vous devez remplir ce champ!"
validate_email :failureMessage => "Merci de saisir une adresse email vaide!"
validate_length :minimum => 10, :maximum => 20, :wrongLengthMessage => "Entre 10 et 20 caractères!"
end
This program is distributed without any warranty. See the file ‘LICENCE’ for details.