© 2026 Hedgehog Software, LLC

TwitterGitHubDiscord
More
CommunitiesDocsAboutTermsPrivacy
Search
Star
Setup for Free
FilamentF
Filament•3y ago•
3 replies
Jay

Custom registration

Hi guys, I created a custom register page as per the documentation here
https://filamentphp.com/docs/3.x/panels/users#customizing-the-authentication-features

Here's the code:

<?php

namespace App\Filament\Pages\Auth;

use Filament\Forms\Components\TextInput;
use Filament\Forms\Form;
use Filament\Pages\Auth\Register as BaseRegister;

class Register extends BaseRegister
{
public function form(Form $form): Form
{
return $form
->schema([
$this->getNameFormComponent(),
$this->getEmailFormComponent(),
TextInput::make('faculty_code')
->required()
->maxLength(255),
$this->getPasswordFormComponent(),
$this->getPasswordConfirmationFormComponent(),
]);
}
}

Question is, how do I run validations on the faculty code field? It should be a valid code (that exists in the faculties table). Would appreciate if someone can point me in the right direction. Thank you!
Users - Panel Builder - Filament
Solution
Okay I was able to achieve this using https://filamentphp.com/docs/3.x/forms/validation#custom-rules
Validation - Form Builder - Filament
Jump to solution
Filament banner
FilamentJoin
A powerful open source UI framework for Laravel • Build and ship admin panels & apps fast with Livewire
20,307Members
Resources
Was this page helpful?

Similar Threads

Recent Announcements

Similar Threads

Custom Registration
FilamentFFilament / ❓┊help
3y ago
Filament custom Registration Form
FilamentFFilament / ❓┊help
3y ago
Custom registration with wizard
FilamentFFilament / ❓┊help
3y ago
Custom registration and email verification
FilamentFFilament / ❓┊help
13mo ago