I have a form built dynamically by php script with a for/loop:
<form id="formDay">
{loop="$elenco"}
<input type="text" name="day[{$value.day}][date]">
{/loop}
</form>
This form I try to validate in this way
$('#formDay').validate({
rules: {
"input[name^='day']": {
required: true,
date: true
}
}
});
but doesn't work because it can not find the fields that beginning with "day". Is it possibile to resolve this problem with this plugin (http://docs.jquery.com/Plugins/Validation)?
UPDATE 1: Sorry, I was my mistake: I wanted to write "day" and not "giornata" ;)