jreviews:admin_route_matched:{:name}
Route-specific action that fires when a JReviews admin route is matched. The route name has dots converted to underscores (e.g., 'listings.index' becomes 'listings_index'). Useful for conditionally loading admin assets or performing actions based on the current admin route.
You need to have a working knowledge of Hooks before you get started.
Fires after route matching on admin requests, before the controller executes
Parameters
| Name | Type | Description |
|---|---|---|
$route |
string |
The original route name (with dots, e.g., 'listings.index') |
$parameters |
array |
Route parameters extracted from the URL |
$request |
\FWD\Illuminate\Http\Request |
The current HTTP request object |
Boilerplate Code
Use the boilerplate code to start using the action, and add your own logic or echo output.
fwd_add_action('jreviews:admin_route_matched:{:name}', function($route, $parameters, $request)
{
// Execute action or echo output
});
Source Files
app/Providers/AssetLoaderServiceProvider.php