Laravel Miscellaneous Helper Function: data_get

November 21, 2016 —John Koster

data_get($target, $key, $default = null)

The data_get function is identical in behavior to both the array_get and object_get function. The difference is that the data_get function will accept both objects and arrays as its $target.

Some absolutely amazing
people

The following amazing people help support this site and my open source projects ♥️
If you're interesting in supporting my work and want to show up on this list, check out my GitHub Sponsors Profile.