This package is no longer supported. Please see the latest Laravel Forum release branch, as the main package now ships with views.
Install the package via composer:
composer require riari/laravel-forum-frontend:~1.0
Then add the service provider to your config/app.php
:
Riari\Forum\Frontend\ForumFrontendServiceProvider::class,
Run the vendor:publish command to publish the package config and views to your app's directories:
php artisan vendor:publish
Once the package is installed, provided you are logged in, you can visit /forum and start defining your category hierarchy using the "Create category" and "Category actions" panels:
The forum.frontend
config file defines the controllers used by the package as well as a closure used to process alert messages to be displayed to the user.
Views are published to resources/views/vendor/forum
. The simplest way to integrate the forum with your existing design is to edit the master view, remove undesired markup and make it extend your application's main layout with @extends
. Note that the master view does pull in jQuery and Bootstrap 3 by default, and includes some jQuery-based JavaScript to support some of the forum frontend features. You may wish to move it elsewhere or re-write it in your own way.
The package includes a variety of events for user interactions such as viewing threads. Refer to src/Events for a full list.