laravel-5.7

Laravel 5.7 How to Log 404 With URL

余生颓废 提交于 2020-05-13 07:49:11
问题 I want to log 404 errors in Laravel 5.7, but I don't understand how to turn this on. Additional to logging 404 errors, I'd like to log the URL that was requested. Other errors are logged correctly. .env APP_DEBUG=true LOG_CHANNEL=stack config/logging.php 'stack' => [ 'driver' => 'stack', 'channels' => ['daily'], ], Per the Error Handling documentation: The $dontReport property of the exception handler contains an array of exception types that will not be logged. For example, exceptions

Laravel 5.7 How to Log 404 With URL

别说谁变了你拦得住时间么 提交于 2020-05-13 07:48:51
问题 I want to log 404 errors in Laravel 5.7, but I don't understand how to turn this on. Additional to logging 404 errors, I'd like to log the URL that was requested. Other errors are logged correctly. .env APP_DEBUG=true LOG_CHANNEL=stack config/logging.php 'stack' => [ 'driver' => 'stack', 'channels' => ['daily'], ], Per the Error Handling documentation: The $dontReport property of the exception handler contains an array of exception types that will not be logged. For example, exceptions

In Router.php line 366: Argument 1 passed to Illuminate\Routing\Router::group() must be of the type array,

懵懂的女人 提交于 2020-03-03 04:52:05
问题 I have update Laravel from v5.7 to v5.8 and now my application doesn't run. I updated it because of this issue: composer require rebing/graphql-laravel fails I solved the packages incompatibility but now Laravel crashes: $ php artisan serve In Router.php line 366: Argument 1 passed to Illuminate\Routing\Router::group() must be of the type array, string given, called in /var/www/masvino/Server-bak/vendor/laravel/framework/src/Illuminate/Support/Facades /Facade.php on line 239 I suspect that

laravel-5.7: data is not saving into database, Object not found

天大地大妈咪最大 提交于 2020-02-06 19:06:31
问题 I'm trying to save data into db but its not saving and says that object not found, can anyone suggest me solution, i am following this tutorial: https://laracasts.com/series/laravel-from-scratch-2018/episodes/10 controller: public function index() { $projects = Project::all(); return view('projects.index', compact('projects')); } public function create() { return view('projects.create'); } public function store() { $project = new Project(); $project->title = request('title'); $project-

laravel-5.7: data is not saving into database, Object not found

删除回忆录丶 提交于 2020-02-06 19:06:26
问题 I'm trying to save data into db but its not saving and says that object not found, can anyone suggest me solution, i am following this tutorial: https://laracasts.com/series/laravel-from-scratch-2018/episodes/10 controller: public function index() { $projects = Project::all(); return view('projects.index', compact('projects')); } public function create() { return view('projects.create'); } public function store() { $project = new Project(); $project->title = request('title'); $project-

laravel-5.7: data is not saving into database, Object not found

混江龙づ霸主 提交于 2020-02-06 19:06:12
问题 I'm trying to save data into db but its not saving and says that object not found, can anyone suggest me solution, i am following this tutorial: https://laracasts.com/series/laravel-from-scratch-2018/episodes/10 controller: public function index() { $projects = Project::all(); return view('projects.index', compact('projects')); } public function create() { return view('projects.create'); } public function store() { $project = new Project(); $project->title = request('title'); $project-

Validate array of inputs in form in Laravel 5.7

不想你离开。 提交于 2020-01-30 12:05:07
问题 My form has the same input field multiple times. My form field is as follows: <input type='text' name='items[]'> <input type='text' name='items[]'> <input type='text' name='items[]'> And request contains ($request['items'): array:1 [▼ "items" => array:3 [▼ 0 => "item one" 1 => "item two" 2 => "item three" ] ] I want atleast one of the items to be filled. My current validation in the controller is $validator = Validator::make($request->all(),[ 'items.*' => 'required|array|size:1' ]); It does

laravel 5.7.15 419 Sorry, your session has expired. Please refresh and try again

旧时模样 提交于 2020-01-21 11:15:06
问题 Hello i am using laravel 5.7.15 i am facing issue <form method="post" action="my_post_Action" class="login100-form validate-form"> <input type="hidden" name="_token" value="B6et9cJOP5wNKodCPgCbAafDjpA5EMcRaaJhEJ9F"> <span class="login100-form-title"> Admin Login </span> <div class="wrap-input100 validate-input" data-validate="Valid email is required: ex@abc.xyz"> <input class="input100" type="text" name="email" placeholder="Email"> <span class="focus-input100"></span> <span class="symbol

Displaying QR Code in PDF file, in Laravel

ぃ、小莉子 提交于 2020-01-16 18:22:13
问题 I'm facing a problem with displaying a QR code in a PDF file. When I try to display the QR code without PDF it works. The QR code is generated by https://github.com/SimpleSoftwareIO/simple-qrcode on to a pdf file generated by https://github.com/barryvdh/laravel-dompdf/tree/0.8.5 StudentController.php: public function view_downlads($id){ $pdf = PDF::loadView('Student.markscardpdf'); return $pdf->stream(); } Student/markscardpdf.blade.php: {{ QrCode::size(200)->generate('hello') }} 来源: https:/

Is it necessary to execute “php artisan key:generate” command after installation of laravel 5.7

删除回忆录丶 提交于 2020-01-15 07:47:36
问题 I have installed laravel 5.7 in my system. I want to know that is it necessary to execute php artisan key:generate command? 回答1: php artisan key:generate This command sets the APP_KEY value in your .env file. If you create a project with composer it'll generated default with project. composer create-project laravel/laravel If you clone project using git clone some folder is ignored by git so you might not get env file as well as vendor folder. Therefore, they will have to manually enter php