The transChoice Method | Laravel 5: String Translation Public API
The Laravel translator also exposes a transChoice method which just acts as an alias to the choice method for backwards compatibility. Their signatures and behavior are the same.
Showing 10 of 2,055 results.
The Laravel translator also exposes a transChoice method which just acts as an alias to the choice method for backwards compatibility. Their signatures and behavior are the same.
config($key = null, $default = null) The config helper function is a versatile function. If the supplied $key and $default value are both null, such as in the following method call: 1 <?php 2 3 // Calling the `config` function without any...
The make:request command can be used to generate new request validation request classes. The command accepts a name for the newly created request class. The name will be used as the name of the class and the file. The following example...
Markdown Tools for Statamic is another freely available add-on (you can find it at https://github.com/JohnathonKoster/statamic-markdown-tools ). It allows site admins to handle text replacements across the entire site (for example, to handle the...
You may have noticed that there are many different sizes of "post images" on this site. One of the first versions of the site that I built used an image with the same dimensions for each place a blog post might appear. For example, on the home...
…I have not specified them for any given post: 1 < meta itemprop = " description " content = " {{ rain_frog : keywords }} " > or a description like so: 1 < meta itemprop = " description " content = " {{ rain_frog : description }} " > The keywords...
The set function can be used to change the entire value of the array. This is accomplished by passing null as the value for $key . When null is used for the $key , the $value will be assigned to the $array variable. The effects of this can be...
Given the following array: 1 $ newArray = [ 2 ' third ' => ' element ' , 3 ' fourth ' => ' element ' 4 ] ; We can reassign the arrays like so: 1 <?php 2 3 use Illuminate \ Support \ Arr ; 4 5 Arr :: set ( $ testArray , null , $ newArray ) ; The...
pull(&$array, $key, $default = null) The pull helper method is similar to the get (covered in the Laravel Array Helper Function: array_get article) method in that it will return a value for the given $key in the $array (or the $default , if it is...
By default, the document parser does not know any custom directives available within an application. This decision was made to help keep the parser as standalone and reusable as possible. However, it is simple to teach the parser about custom...