Highlights active field in a form and allows to add a class to every fields, except radio and checkbox
Parameters
| form_id | The id of the formular. By default it is ‘mainform’. |
| setBorder | If you want to add a class to each fields, except radio and checkbox. |
| elementClass | The class to apply to each fields. By default it is ‘input_f’. |
| txtcolor | Text color when it is highlighted. |
| bgcolor | Background-color when it is highlighted. |
| duration | Duration of the fade effect. |
Exemple
You can initialize a focus by adding this in your html head this code :
<script type="text/javascript">
window.addEvent('domready', function() {
var myFocus = new Focus({
form_id : 'mainform',
setBorder : true,
txtcolor : '#000000',
bgcolor : '#ffffff',
elementClass : 'input_f',
duration : 742
});
});
</script>
Require
Core
* Core.js
Class
* Class.js
About
focus.js v.1.0 for mootools v1.1 05 / 2007
by Floor SA (http://www.floor.ch) MIT-style license
created by David Mignot and Luca Pillonel, last modified by David Mignot 05 june 07
Summary
| Highlights active field in a form and allows to add a class to every fields, except radio and checkbox |
| |
| |
| |
| |
| |