Have you ever had to show a combination of columns of data from table or process data before saving it to the database. The answer would probably be yes, who doesn’t. This is where the concept of Accessors and mutators come in handy.

laravel accessors

Let me show you what they mean and how they work.