Search

Showing 7 of 1,216 result(s)

/blog/2018/04/15/laravel-5-conditionally-transformingchanging-values-with-transform

The transform helper function is used to modify the provided value if the value contains a "non-empty" value. A value is considered to be "empty" or "blank" if it meets one of the following conditions: The value is, null, ,, The value is a string...

/blog/2018/04/15/laravel-5-determining-if-a-variable-holds-a-value-with-blank

The blank function is used to determine if the provided value contains a value that is not null , or a non empty value. It can be useful to check arguments supplied to functions for values without having to check many different types specifically....

/blog/2018/04/15/laravel-5-determining-which-traits-a-class-uses-with-trait_uses_recursive

The trait_uses_recursive function will return an array of all the traits that are used by a class. It will also return any traits that the traits are using.The signature of the trait_uses_recursive function is:Given the traits and class: The...

/blog/2018/04/15/laravel-5-displaying-variable-data-and-stopping-script-execution-for-debugging-with-dd

The dd function is a debug utility that will display useful information about the objects or values supplied. This function will also prevent further execution of the script; it will dump the values of the supplied arguments and die (exit the...

/blog/2018/04/15/laravel-5-finding-what-traits-a-class-uses-with-class_uses_recursive

The class_uses_recursive function is functional similar to the trait_uses_recursive function. It will return an array of all the traits that are used by the given class, its traits and any base classes.The signature of the class_uses_recursive...

/blog/2018/04/15/laravel-5-get-the-current-date-with-today

The today helper function is similar to the now helper function in that it returns a Carbon for the current date, however, the difference is that the today helper function only returns the date component; the time component is set to 00:00:00 ....