PHP code example of zrkb / nexus
1. Go to this page and download the library: Download zrkb/nexus library . Choose the download type require .
2. Extract the ZIP file and open the index.php.
3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
zrkb / nexus example snippets
'providers' => [
'admins' => [
'driver' => 'eloquent',
'model' => \Nexus\Models\Admin::class,
],
// ...
],
// Model
app/Models/Bookmark.php
// Controller
app/Http/Controllers/Backend/BookmarkController.php
// Migration
database/migrations/YYYY_MM_DD_HHIISS_create_bookmarks_table.php
// Views
resources/views/bookmarks/create.blade.php
resources/views/bookmarks/edit.blade.php
resources/views/bookmarks/form.blade.php
resources/views/bookmarks/index.blade.php
resources/views/bookmarks/show.blade.php
Nexus::resource('bookmarks', 'BookmarkController');
Nexus::group(function () {
Route::resource('bookmarks', 'BookmarkController');
});
<li>
<a href="{{ route('bookmarks.index') }}"
class="nav-link {{ is_route('bookmarks.index') ? 'active' : '' }}"
role="button">
<i class='bx bx-bookmarks'></i>
<span>Bookmarks</span>
</a>
</li>
bash
$ php artisan nexus:install
bash
$ php artisan nexus:user
bash
$ php artisan nexus:crud Bookmark