Category : routes

this is route Route::post(‘/delete/comment/{comment}’, ‘[email protected]’)->name(‘comment.delete’); this is function public function deleteAttachment(Comment $comment){ dd($comment); } and this is where I’m trying to use it <a target="_blank" class="btn btn-outline-danger function mr-2 " href="{{route(‘backend.ticket.comment.delete’,[‘comment’=>$comment->id])}}"><i class="mdi mdi-delete"></i></a> and this is error: The GET method is not supported for this route. Supported methods: POST. Sourc..

Read more

this is route Route::post(‘/delete/comment/{comment}’, ‘[email protected]’)->name(‘comment.delete’); this is function public function deleteAttachment(Comment $comment){ dd($comment); } and this is where I’m trying to use it <a target="_blank" class="btn btn-outline-danger function mr-2 " href="{{route(‘backend.ticket.comment.delete’,[‘comment’=>$comment->id])}}"><i class="mdi mdi-delete"></i></a> and this is error: The GET method is not supported for this route. Supported methods: POST. Sourc..

Read more

Error Image here Login Route Route::get(‘/’, [HomeController::class, ‘index’]) ->name(‘index’) ->breadcrumbs(function (Trail $trail) { $trail->push(__(‘Home’), route(‘frontend.index’)); }); Authentication Routes Route::get(‘login’, [LoginController::class, ‘showLoginForm’])->name(‘login’); Route::post(‘login’, [LoginController::class, ‘login’]); Problem: My project is working fine when i run it locally but when i upload it on server it shows Method Not Allowed exception. I don’t know why. When i used ..

Read more

Actually i’m trying to incoporate a little group of extra functions inside of a resource type controller i have defined the actions in the controller and also defined the routes i wish to be used there: 1. Route::resource(‘/stores’, StoresController::class); 2. Route::get(‘/stores/attributes/{store}’, [StoresController::class, ‘attributes’])->name(‘attributes.index’); 3. Route::get(‘/stores/attributes/{store}/create/’, [StoresController::class, ‘attributesCreate’])->name(‘attributes.create’); first row is the common resource routes definition, ..

Read more

Como resolvo este erro? Comecei a programar muito recentemente, então perdoem erros, por favor. Estou presa nesse problema umas horas, não tenho ideia de como resolver. Estou tentando fazer um simples tutorial com uma lista indexadora lateral e o erro View [painel.templates.template_erros] not found. (View: C:wamp64wwwprojetoresourcesviewserrors4.blade.php) aparece pra mim. Já tentei usar todas as formas ..

Read more

I upload a laravel project on server; When I run all the post request , at first return this error: Request URL: http://example.com/user/register/ Request Method: POST Status Code: 301 Moved Permanently And then this occure: Request URL: http://example.com/user/register Request Method: GET Status Code: 500 Internal Server Error (from disk cache) Post method change to get ..

Read more

i am run this command for model, migration, resource controller. php artisan make:model QuestionAnswer -mc -r .. My Edit Function public function edit(QuestionAnswer $questionAnswer) { // return $questionAnswer; return view(‘backend.faq.edit’,get_defined_vars()); } Route one {{route(‘admin.faq.edit’,$questionAnswer->id)}} Route two Route::resource(‘question-answer’,’QuestionAnswerController’); in Edit function for Route one : $questionAnswer object return null. but for Route two : $questionAnswer return ..

Read more

I am running this command for model, migration, resource controller. `php artisan make:model QuestionAnswer -mc -r` .. My Edit Function public function edit(QuestionAnswer $questionAnswer) { // return $questionAnswer; return view(‘backend.faq.edit’,get_defined_vars()); } Route one in web.php : Route::resource(‘faq’,’QuestionAnswerController’); in view : {{route(‘admin.faq.edit’,$questionAnswer->id)}} Route two in web.php : Route::resource(‘question-answer’,’QuestionAnswerController’); in view {{route(‘admin.question-answer.edit’,$questionAnswer->id)}} in Edit function for Route ..

Read more

After installing laravel 7 version, I immediately installed ui: auth, ran the php artisan ui bootstrap –auth command (for installation with bootstrap markup), initially everything worked, I had no trouble, but now when going to the pages (Login, registration, reset password) I have a 404 error. web.php (route file) <?php use IlluminateSupportFacadesRoute; /* |————————————————————————– | ..

Read more

I’ve added link to script from another site: <div data-get-fit-index-lk="">&nbsp;</div> <script src="https://reservi.ru/widget-fit1c.v2/js/config.js" data-fit-salon-id="xxxx"> </script> It embeds page with functions of calendar and planning . So i’ve got a problem. First it was error about route, so I’ve added route::any (there was only ‘get’). And after logging into embedded page with this script (it has own ..

Read more

i am run this command for model, migration, resource controller. php artisan make:model QuestionAnswer -m -r .. Resource Route Route::resource(‘faq’,’QuestionAnswerController’); My Edit Function public function edit(QuestionAnswer $questionAnswer) { // return $questionAnswer; return view(‘backend.faq.edit’,get_defined_vars()); } Edit Route {{route(‘admin.faq.edit’,$questionAnswer->id)}} Edit function return $questionAnswer return null Below Picture When i Change resource route like model name Route::resource(‘question-answer’,’QuestionAnswerController’); edit ..

Read more

I am not sure if I have phrased my question correctly in the title. My problem is, if my current URL is: ‘http://127.0.0.1:8000/admin/details/4’ and if I click on Homepage it should redirect to ‘http://127.0.0.1:8000/admin/home’ but in fact, it redirects to something like this: ‘http://127.0.0.1:8000/admin/details/admin/home’ //routes Route::get(‘/home’, [AppHttpControllersHomeController::class, ‘index’])->name(‘home’); Route::get(‘history’, [AppHttpControllersHomeController::class, ‘history’])->name(‘history’)->middleware(‘auth’); Route::get(‘admin/home’, [HomeController::class, ‘adminHome’])->name(‘admin.home’)->middleware(‘is_admin’); Route::get(‘admin/details/{id}’, ..

Read more

Morning! I’m programming a laravel 7 multitenancy project using hyn package version 5.6 For now i have a principal app (localhost) and a subdomain (tecnotienda.localhost). But when i route them it ussually overlaps, i mean: it just shows the principal or just shows the subdomain. This is my routes/web.php <?php use IlluminateSupportFacadesRoute; use AppHttpControllersReportController; /* ..

Read more

Related to: Fleet cart using middlewares in routes but i can not find any $routemiddleware in project…not even in kernel.php …where can i find it? I have an installation of Laravel 5.7 using FleetCart module on my website. Fleetcart is already handling some (or all? not sure) endpoints; in addition to that I want to ..

Read more

this is where I need middlware public function getFileAttribute() { return route(‘backend.file_url’, [ ‘path’ => $this->attributes[‘attachment’], ]); } this is my route Route::get(‘file-url’, ‘[email protected]’)->name(‘file_url’); I want to use middlaware Like this but not in web.php or api.php I need it in controller Route::get(‘/download/{ticket}’, ‘[email protected]’)->name(‘download’)->middleware([‘can:download,ticket’]); Sourc..

Read more

I have created the two resource controller inside two different route groups. One for User One for Admin Route::group([ ‘prefix’ => ‘dashboard’, "middleware" => ‘auth’, "namespace" => ‘User’ ], function (){ Route::resource(‘projects’, ‘ProjectController’); }) Route::group([ ‘prefix’ => ‘admin’, "middleware" => ‘auth’, "namespace" => ‘Admin’ ], function (){ Route::resource(‘projects’, ‘ProjectController’); }) I am using the ‘route’ ..

Read more