MVC for web development: Sign-up form?
- by incrediman
How would I go about implementing a signup form using the MVC pattern for a website (I'm using PHP)?
I think the controller should receive the POST data initially. Then probably some interation with the model might need to take place (if the user successfully signs up). Then I think the signup form view would be called, and a value would be passed in saying whether or not the signup was successful.
Stuff I need help with:
Where do I do input validation (ie. proper email address formatting)? How do I check to make sure the username is unique?
Is the rest of my description alright?
How would you go about doing an MVC website signup form?