I have a problem with my app on the server.
When I access it through various links, it works. But, when I put the URL to the same site in my browser, I get a NotFoundHttpException
. What I have detected in the message of the exception are the following problems:
REDIRECT_URL /app/public//login
REQUEST_URI /app/public//login
I do not understand why it adds two slashes ( //
) after public
instead of one ( /
).
The code for my file route.php
is:
Route::get('login', 'UserController@get_index');
And, the code for my Controller is:
public function get_index()
{
return View::make('admin.login');
}
I think changing the naming convention to the one laravel uses will fix this problem.
Do this in your routes:
Route::get('login', 'UserController@getIndex');
and this in the controller:
public function getIndex()
{
return View::make('admin.login');
}
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.