lundi 7 août 2017

Multi-auth not working 5.4

i got 2 user which is seller and user. Login function for both is fine but when i login to seller there is no logout button. enter image description here

Route:

Route::post('/logout', 'Auth\PsController@logout');

});

psblade:

                 <ul class="nav navbar-nav navbar-right">
                    <!-- Authentication Links -->
                    @if (Auth::guest())
                        <li><a href="">Loginnn</a></li>
                        <li><a href="">Registerr</a></li>
                    @else
                        <li class="dropdown">
                            <a href="#" class="dropdown-toggle" data-toggle="dropdown" role="button" aria-expanded="false">
                                 <span class="caret"></span>
                            </a>

                            <ul class="dropdown-menu" role="menu">
                                <li>
                                    <a href=""
                                        onclick="event.preventDefault();
                                                 document.getElementById('logout-form').submit();">
                                        Logout
                                    </a>

                                    <form id="logout-form" action="" method="POST" style="display: none;">
                                        
                                    </form>
                                </li>
                            </ul>
                        </li>
                    @endif



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

Aucun commentaire:

Enregistrer un commentaire