Can't register new user with username I'm doing Laravel from scratch and I'm stuck here: https://laracasts.com/series/laravel-6-from-scratch/episodes/64?autoplay=true
I followed along, but I can't figure out why every time I try to register I get "The username field is required." on the username field. Here's what my the form for the username looks like:
<div class="form-group row">
<label
for="username"
class="col-md-4 col-form-label text-md-right">
Username
</label>
<div class="col-md-6">
<input id="username" type="text"
class="form-control @error('username') is-invalid @enderror"
username="username" value="{{ old('username') }}" required
autocomplete="username" autofocus>
@error('username')
<span class="invalid-feedback" role="alert">
<strong>{{ $message }}</strong>
</span>
@enderror
</div>
</div>
sorry about the rough format. It's really hard to line it up.
You have to have name attribute name="username" and not username="username"
<input id="username" type="text"
class="form-control @error('username') is-invalid @enderror"
name="username" value="{{ old('username') }}" required
autocomplete="username" autofocus>
AH! Wow, thanks. I just replaced everything with username I suppose.
Please sign in or create an account to participate in this conversation.