Skip to content

Instantly share code, notes, and snippets.

@jokamjohn
Created January 20, 2016 04:07
Show Gist options
  • Select an option

  • Save jokamjohn/41a0fa8a3d6d3f48ec7f to your computer and use it in GitHub Desktop.

Select an option

Save jokamjohn/41a0fa8a3d6d3f48ec7f to your computer and use it in GitHub Desktop.
Create a birthday laravel
<div class="form-group {{ $errors->has('date_of_birth') ? 'has-error' : '' }}">
{{ Form::label('date_of_birth', 'Date of Birth', ['class' => 'control-label']) }}
<div class="form-inline">
{{ Form::selectRange('date_of_birth[day]', 1, 31, null, ['class' => 'form-control']) }}
{{ Form::selectMonth('date_of_birth[month]', null, ['class' => 'form-control']) }}
{{ Form::selectYear('date_of_birth[year]', date('Y') - 3, date('Y') - 16, null, ['class' => 'form-control']) }}
</div>
{{ $errors->first('date_of_birth', '<span class="help-block">:message</span>') }}
</div>
@aralovelace
Copy link
Copy Markdown

Date of Birth Laravel Forms

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment