Extending The Connection Class In Laravel
Published on by Eric L. Barnes
Sometimes you may wish to extend the database Connection class in Laravel. Maybe you want to customize the internal workings. In my case I needed to alter the database results for every query, whether it’s through the Fluent Query Builder or Eloquent. I needed to do this to make my package, Laravel DB Normalizer, work as smoothly as possible.
Eric is the creator of Laravel News and has been covering Laravel since 2012.