Hidden value filled by other input
Hi! What would be the best way to have InputA in the form visible where the user can type something and have InputB hidden in the form that is populated by something from InputA.
- InputA you fill in a Discord username
- After typying is done you fetch the userid from the discord user
- InputB (hidden in the form) will be populated with the discord userid
- Create record. And InputB will be sent off as value for creating that record.
What would be the right way to do so?
4 Replies
I did got it working doing this. But the player is still in the array?
If you don’t need player to be saved you can use ->dehydrated(false) so it’s not part of the data that gets saved.
Aaah thanks! Ill add that 🙂
Got it working! Also with a little hap from Dan!