Search

Showing 7 of 1,216 result(s)

/blog/2018/04/21/laravel-5-fluent-api-the-public-api#content-example-use-4

The following code: would be converted into the following JSON, stored in the $jsonValue variable: Alternatively, a well-formatted value can be returned by passing in the JSON_PRETTY_PRINT constant: This time, the $jsonValue would contain the...

/blog/2018/04/21/laravel-5-fluent-api-the-public-api#content-tojson-and-deeply-nested-data-structures

The toJson method internally makes a call to PHP's json_encode function. Unlike json_encode , toJson does not provide a way to specify the depth (essentially how many arrays are nested inside of each other) to which data will be encoded, which is...

/blog/2018/04/21/laravel-5-macros-call-and-callstatic#content-macroable-implementation-of-phps-magic-callstatic-method

The Macroable trait implements PHP's magic __callStatic method to intercept calls to a methods when in static context that do not exist on the target class. If a macro with the given method name is found, it is evaluated and the result returned....

/blog/2018/04/21/laravel-5-macros-call-and-callstatic#content-important-notes-on-call-and-callstatic

Because Macroable depends on both the __call and __callStatic methods to be available for its own use, it is currently not possible to use the Macroable trait in a class that also requires returning a value from either __call or __callStatic...

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.