Laravel 4: Default Events

1 min read

Laravel 4 provides a few events that are fired throughout your applications life cycle. This should just serve as a quick reference if you need to find where an event is called or what events are available.

Event File
auth.attempt /Illuminate/Auth/Guard.php
auth.login /Illuminate/Auth/Guard.php
auth.logout /Illuminate/Auth/Guard.php
illuminate.query /Illuminate/Database/Connection.php
illuminate.query.failed /Illuminate/Queue/Worker.php
illuminate.log /Illuminate/Log/Writer.php
router.matched /Illuminate/Routing/Router.php
composing: {view name} /Illuminate/View/Environment.php
creating: {view name} /Illuminate/View/Environment.php
artisan.start /Illuminate/Console/Application.php
locale.changed /Illuminate/Foundation/Application.php
illuminate.app.down /Illuminate/Foundation/Application.php

In the above table, {view name} will become the name of the view you are looking for. For example, if you had a view named hello, you would use listed for the event composing: hello.

This page will be updated with additional information about each event, and other events that may be available.

Thanks for taking the time to read this post! If you found this article useful and want to help support more work like this, please consider sponsoring my work on GitHub, or by checking out some merch.

 Sponsor on GitHub  Shop Merch