I have textbox and i need to show alert message whenever user enters value greater then 100
for example in the field age if user enters value greater than 100 alert should pop up
function form_fields($values = array())
{
$fields = parent::form_fields();
$CI =& get_instance();
$CI->load->module_model(Example_FOLDER, 'example_to_permissions_model');
$CI->load->module_model(Example_FOLDER, 'example_to_users_model');
$fields['user']['label'] = 'username';
$fields['vAge']['label'] = 'Age';
$fields['height']['label'] = 'Height';
return $fields;
}
Comments
$("#target").keypress(function() { if ($(this).val() > 100) alert(); });
Without any context, personally I'd leave the validation and notifications the 'FUEL' way for consistency with other messages.