I have this input but its not working because i have in name []. Any suggestion how can i fix this? If i remove this [] required is working.
@foreach ($languages as $language)
<input type="text" id="text-title" name="article_title[]" value="" class="form_input" required="required">
@endforeach
<button type="submit" class="submit_property bg_green pull-right">CREATE ARTICLE</button>
validation rules:
public function rules()
{
return [
'article_title' => 'required:articles',
'slug' => 'required|unique:articles',
}
Problem is that i need required rule only if $language->id = 1
from Newest questions tagged laravel-5 - Stack Overflow http://ift.tt/2iNdUan
via IFTTT
Aucun commentaire:
Enregistrer un commentaire