© 2026 Hedgehog Software, LLC

TwitterGitHubDiscord
More
CommunitiesDocsAboutTermsPrivacy
Search
Star
Setup for Free
FilamentF
Filament•2y ago•
4 replies
🤖transistor🤖

How the get the option label from a select

So, I've got a
Select
Select
and I want to fill a
TextInput
TextInput
with the value selected. Not the value of the option, but the label.
Say, I've got
<select>
  <option value="1">something</option>
</select>
<select>
  <option value="1">something</option>
</select>

When the user selects
something
something
I want to fill a
TextInput
TextInput
with
something
something


My
Select
Select
looks like this:
Forms\Components\Select::make('exchange_rate_id')
    ->relationship('exchange_rate', 'rate')
    ->searchable()
    ->preload()
    ->live()
    ->reactive()
Forms\Components\Select::make('exchange_rate_id')
    ->relationship('exchange_rate', 'rate')
    ->searchable()
    ->preload()
    ->live()
    ->reactive()

and my
TextInput
TextInput
:
Forms\Components\TextInput::make('exchange_rate')
    ->numeric()
    ->key('exchangeRate')
Forms\Components\TextInput::make('exchange_rate')
    ->numeric()
    ->key('exchangeRate')


I've tried using
afterStateUpdated
afterStateUpdated
injecting the state, the component, Get, Set, but the only thing I can get is the
option
option
value (1 in this example).
How can I get
something
something
from the selected option? Thanks in advance.
Filament banner
FilamentJoin
A powerful open source UI framework for Laravel • Build and ship admin panels & apps fast with Livewire
20,307Members
Resources

Similar Threads

Was this page helpful?
Recent Announcements

Similar Threads

How to get the select option label using $get?
FilamentFFilament / ❓┊help
3y ago
Modifying the option label in Select
FilamentFFilament / ❓┊help
3y ago
Customizing option label from select with relationship
FilamentFFilament / ❓┊help
3y ago
How to cutomize selected option label?
FilamentFFilament / ❓┊help
3y ago