samedi 25 novembre 2017

Form parameters not getting sent?

I am trying to make a login request but for some reason none of the inputs are getting sent with the request.

Have a bad feeling it's just some stupid mistake but I have been looking for 2h now and I can't find anything.

CODE:

Html / Laravel Blade:

<form method="POST" action="">
    
    <div class="row">
        <div class="input-field col s12">
            <input id="username" name="username" type="text" class="validate" required>
            <label for="username" data-error="wrong" data-success="right">Username</label>
        </div>
    </div>
    <div class="row">
        <div class="input-field col s12">
            <input id="password" name="password" type="password" class="validate" required>
            <label for="password" data-error="wrong" data-success="right">Password</label>
        </div>
    </div>
    <div class="row">
        <div class="input-field col s12">
            <button class="btn btn-block waves-effect waves-light" type="submit" name="submit">Login</button>
        </div>
    </div>
</form>

Route:

Route::post( '/admin/login', 'Auth\AdminLoginController@login' )->name( 'admin.login' );

Controller:

public function login( Request $request )
{
    dd($request);
}

Result:

enter image description here

Thanks



from Newest questions tagged laravel-5 - Stack Overflow http://ift.tt/2zpVUrF
via IFTTT

Aucun commentaire:

Enregistrer un commentaire