Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.

leonidas's avatar

Resource Controller with multi-stage form or session

I have been listening to the Laravel Snippet podcast and Taylor describes to clean up code try and stick to the traditional resource controller methods - create, update etc.

How is this accomplished when you have a multi-stage form with a Session? I was thinking that you have a hidden form field to deduce which stage in the form you are in. Therefore the correct validation can be called by use of a switch statement in the create method and then store the valid data in the session.

0 likes
0 replies

Please or to participate in this conversation.