2 weeks ago

Create Method with Validating Only Some Fields

Posted 2 weeks ago by moshemo

I am referencing this episode:

Jeffrey notes a way to use the create with the validate method -- like this:

 'title' => 'required',
 'excerpt' => 'required',
 'body' => 'required'

My question is how could I rework this code if I only wanted to validate some of the fields (so, only the title field). How could I do that?


Please sign in or create an account to participate in this conversation.