Answer the question
In order to leave comments, you need to log in
How to shorten code without ajax?
Here I am writing a validation
Valid.Make({
name: "required|max:25",
email: "required|email|max:255",
password: "required|min:6|confirmed"
}, {
name: {
required: "{{trans('validation.custom.name.required')}}",
max: "{{trans('validation.custom.name.max')}}"
},
email: {
required: "{{trans('validation.custom.email.required')}}",
email: "{{trans('validation.custom.email.email')}}",
max: "{{trans('validation.custom.email.max')}}"
},
password: {
required: "{{trans('validation.custom.password.required')}}",
min: "{{trans('validation.custom.password.min')}}",
confirmed: "{{trans('validation.custom.password.confirm')}}"
}
}, [
'<div class="message padd_top_10 padd_bot_10 red"><p>',
'</p></div>'
], 'form1');
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question