久久久久久久av_日韩在线中文_看一级毛片视频_日本精品二区_成人深夜福利视频_武道仙尊动漫在线观看

Laravel 5.4 禁用注冊(cè)路由

Laravel 5.4 Disable Register Route(Laravel 5.4 禁用注冊(cè)路由)
本文介紹了Laravel 5.4 禁用注冊(cè)路由的處理方法,對(duì)大家解決問(wèn)題具有一定的參考價(jià)值,需要的朋友們下面隨著小編來(lái)一起學(xué)習(xí)吧!

問(wèn)題描述

我正在嘗試禁用在 Laravel 5.4 中運(yùn)行的應(yīng)用程序上的注冊(cè)路由.

I am trying to disable the register route on my application which is running in Laravel 5.4.

在我的路由文件中,我只有

In my routes file, I have only the

Auth::routes();

有什么辦法可以禁用注冊(cè)路由嗎?

Is there any way to disable the register routes?

推薦答案

code:

Auth::routes();

這是這組路線的捷徑:

// Authentication Routes...
Route::get('login', 'AuthLoginController@showLoginForm')->name('login');
Route::post('login', 'AuthLoginController@login');
Route::post('logout', 'AuthLoginController@logout')->name('logout');

// Registration Routes...
Route::get('register', 'AuthRegisterController@showRegistrationForm')->name('register');
Route::post('register', 'AuthRegisterController@register');

// Password Reset Routes...
Route::get('password/reset', 'AuthForgotPasswordController@showLinkRequestForm')->name('password.request');
Route::post('password/email', 'AuthForgotPasswordController@sendResetLinkEmail')->name('password.email');
Route::get('password/reset/{token}', 'AuthResetPasswordController@showResetForm')->name('password.reset');
Route::post('password/reset', 'AuthResetPasswordController@reset');

因此,您可以用路由列表替換第一個(gè),并注釋掉您的應(yīng)用程序中不需要的任何路由.

So you can substitute the first with the list of routes and comment out any route you don't want in your application.

編輯 laravel 版本 =>5.7

在較新的版本中,您可以向 Auth::routes() 函數(shù)調(diào)用添加一個(gè)參數(shù)以禁用注冊(cè)路由:

In newer versions you can add a parameter to the Auth::routes() function call to disable the register routes:

Auth::routes(['register' => false]);

添加了電子郵件驗(yàn)證路徑:

The email verification routes were added:

Route::get('email/verify', 'AuthVerificationController@show')->name('verification.notice');
Route::get('email/verify/{id}', 'AuthVerificationController@verify')->name('verification.verify');
Route::get('email/resend', 'AuthVerificationController@resend')->name('verification.resend');

順便說(shuō)一句,您還可以禁用 Password ResetEmail Verification 路由:

BTW you can also disable Password Reset and Email Verification routes:

Auth::routes(['reset' => false, 'verify' => false]);

這篇關(guān)于Laravel 5.4 禁用注冊(cè)路由的文章就介紹到這了,希望我們推薦的答案對(duì)大家有所幫助,也希望大家多多支持html5模板網(wǎng)!

【網(wǎng)站聲明】本站部分內(nèi)容來(lái)源于互聯(lián)網(wǎng),旨在幫助大家更快的解決問(wèn)題,如果有圖片或者內(nèi)容侵犯了您的權(quán)益,請(qǐng)聯(lián)系我們刪除處理,感謝您的支持!

相關(guān)文檔推薦

add new element in laravel collection object(在 Laravel 集合對(duì)象中添加新元素)
Creating an edit modal in Laravel 5(在 Laravel 5 中創(chuàng)建編輯模式)
Laravel 5.5 API resources for collections (standalone data)(用于集合的 Laravel 5.5 API 資源(獨(dú)立數(shù)據(jù)))
What is the best practice to create a custom helper function in php Laravel 5?(在 php Laravel 5 中創(chuàng)建自定義輔助函數(shù)的最佳實(shí)踐是什么?)
No #39;Access-Control-Allow-Origin#39; header - Laravel(沒(méi)有“Access-Control-Allow-Origin標(biāo)頭 - Laravel)
Laravel Passport Route redirects to login page(Laravel Passport Route 重定向到登錄頁(yè)面)
主站蜘蛛池模板: 男女羞羞免费视频 | 欧美日韩中文在线观看 | 啪啪av| 亚洲精品www久久久久久广东 | 嫩草黄色影院 | 美国十次成人欧美色导视频 | 一级片在线观看 | 粉嫩高清一区二区三区 | 亚洲一区二区在线 | www.99re5.com| 精彩视频一区二区三区 | 成人h视频在线观看 | 欧美精品综合在线 | 国产欧美精品在线 | 亚洲 欧美 日韩 精品 | japan25hdxxxx日本| 99热这里有精品 | 天天综合91 | 午夜精品一区二区三区在线观看 | 99精品久久久久久 | 一级免费a | 亚洲成人一区二区 | 国产精品一区二区三区久久 | 久久综合久色欧美综合狠狠 | 日韩精品一二三 | 亚洲成人动漫在线观看 | 国产成人av一区二区三区 | 亚洲资源在线 | 成人在线亚洲 | 国产精品高潮呻吟久久 | 欧美一级黄视频 | 午夜在线 | 亚洲精品成人免费 | 超碰97免费观看 | 精品视频一区二区 | 国产一级视频在线 | 综合精品久久久 | 一级在线观看 | 一本色道精品久久一区二区三区 | 999观看免费高清www | 欧美天堂在线观看 |