retrieve Radio value in custom page.
im currently developing a custom page to answer a quiz. $this->form contains Radio input. when i select an option and save the answer, everything works fine, like showing explanation and right/ wrong icons. however if when i reload the page $this->form is empty. how to set the value for the radio input?
11 Replies
say this is the link http://127.0.0.1:8000/qpq/quizzes/22/attempt/56
i want to be able to retrieve the option from id question 56
where are you filling the form when the page loads
by default this is the $form
this is when i click on save & next (the page does not reload)
this is when i reload, everything is not there because $this->form has nothing i guess
right but i dont see where you've even attempted to tell Filament where the initial data should come from
this is my mount method
you havent called
$this->form->fill()
with your data?inside fill() it can accept for example $something as parameter?
please check the Getting Started docs on the form builder
thanks
found it