-
Notifications
You must be signed in to change notification settings - Fork 0
Portal Users
Phillip Dornauer edited this page Apr 1, 2026
·
1 revision
Portal users are frontend visitors who can log in to access restricted content. They are completely separate from admin users.
Go to System → Portal Users in the admin.
| Property | Description |
|---|---|
| Login email | |
| Password | Hashed login password |
| Enabled | Disabled accounts cannot log in |
| Item | Optionally link the user to a content item (e.g. a team member profile) |
| Route | Description |
|---|---|
GET /portal/login |
Login form |
POST /portal/login |
Submit credentials |
GET /portal/register |
Registration form |
POST /portal/register |
Submit registration |
POST /portal/logout |
Sign out |
Route::get('/members', MembersController::class)
->middleware('marble.portal.auth');Unauthenticated visitors are redirected to /portal/login.
@if(Marble::isPortalAuthenticated())
<p>Welcome, {{ Marble::portalUser()?->email }}</p>
<form action="{{ route('marble.portal.logout') }}" method="POST">
@csrf <button type="submit">Sign out</button>
</form>
@else
<a href="{{ route('marble.portal.login') }}">Sign in</a>
@endifA portal user can be linked to a content item for personalized content:
@php $profile = Marble::portalUser()?->item; @endphp
@if($profile)
<h2>{{ $profile->name() }}</h2>
<p>{{ $profile->value('bio') }}</p>
@endif@if(!Marble::isPortalAuthenticated())
<p>This section is for employees only.</p>
<a href="{{ route('marble.portal.login') }}">Sign in</a>
@else
<h1>{{ $item->name() }}</h1>
{!! $item->value('content') !!}
@endif