Skip to content

Tag: laravel-8

Call to a member function notify() on null in Laravel 8

I want to send an SMS to a mobile phone (if he had already turned on the two-factor authentication system). So at LoginController I added this method: And this loggendin method is inside of a trait called TwoFactorAuthentication, which goes like this: Now the problem is when I want to log in, this message app…

Laravel 8 Does Not Show Data From DB

I’m working with Laravel 8 and I have made a resource Controller to return some results from MySQL table so index() method of this Controller holds: At at index.blade.php I added this: So as you can see, it look fine but the problem is it does not show me any output! I mean no results and no errors at a…

Catch HTTP client errors in Laravel 8

How do you catch errors thrown by the HTTP client (for example a time out) so that it doesn’t throw the curl error in the Laraval debugger (in debug mode) before you can do anything with the error to avoid stopping the execution? Instead, I’m always getting the Laravel’s Ignition error page …