There isn't displays authentication block in Laravel project - laravel

I'm completely new in Laravel. I don't understand why authentication block doesn't displays after I installed laravel/ui and php artisan make:auth command. These pages have been added. But there aren't any special routes in routes list. code

In web.php you have to use
Auth::routes();

Related

How to access laravel api from vuejs frontend?

I have built a laravel api, I have placed the backend inside a laravel folder in the cpanel and the built vuejs frontend inside public_html, now u can see I am using both api.php and web.php, my frontend is working fine when I visit https://www.example.com but what's the url to my api endpoints since when I try something like https://www.example.com/api/somepage it doesn't work it just hits the routes I set using vue router?
Please I need help here I am a beginner, and thanks in advance.
Laravel apis have default middleware to establish security. Make sure you send tokens. In my opinion, test it in postman first.
If you have a 404 error , this link can help you
Sometimes it is possible that there is a problem with the route cache, so it is better to delete the route cache and create it again
php artisan route:clear
php artisan route:cache

How to set name for a laravel fortify route?

I'm a little curious, sorry for the silly question.
I wanted to get the route for login in the Laravel 8 + Fortify stack, it seems I cannot use "/login" directly because it will append on URL. so I wanted to use
{{ route('login') }}
But the problem is, it gives me an error 'route not defined'. When I'm running the command route:list it shows a blank name for login and register but has a name for 'logout'
I wonder how I can give a name for the fortify route, as it is not declared in the routes.web
Try:
php artisan route:clear
php artisan route:cache
This will clear all the route cache in Laravel.
You should Try :
php artisan optimize:clear
It help you clear your application cache route and config as well.

Install authentication in laravel

I'm proceeding with the first installation of Laravel 8, everything is ok, I also installed the authentication system via commands:
composer require laravel/ui
php artisan ui vue --auth
Unfortunately, I can't find any auth folders on the controller.
Furthermore, there is also no auth.php route
Can you tell me how to do it? How do I proceed?
PS: I would also like not to rely on any UI as bootstrap or whatever, but on my assets css and js. (I hope I have explained)
Run php artisan ui:controllers to scaffold the auth controllers.

Route [auth.login] not defined. laravel 8

I'm getting this error out of a sudden after everything was working fine. ra
Although Auth::routes() is included, as a general rule, you can always check list of routes with names and middlewares by:
php artisan route:list
You'll probably see login not auth.login. auth.login is a view not route. If you can't find login you probably need to cache routes by:
php artisan route:cache

Voyager admin panel links are broken

What is my problem: I make application using Laravel 5.5. I want had my application url like www.example.com/shop, and navigation in dashboard voyager panel are broken. Links goes to www.example.com/admin/{slug} instead www.example.com/shop/admin/{slug}.
Iv tried already change prefix routes
Route::group(['prefix' => 'shop/admin'], function () {
Voyager::routes();
});
then navigation links goes to www.example.com/shop/{slug} but admin panel href change to www.example.com/shop/shop/...
I changed APP_URL to www.example.com/shop in env.
I won't change links using static href in menus builder cos many application use this same database.
I think your APP_URL should be www.example.com (without /shop). Try to run php artisan route:clear and php artisan route:list and see what URI's you get.

Resources