Search

Showing 7 of 1,216 result(s)

/blog/2016/11/30/laravel-string-pluralization#content-examples-of-specific-numbers

The following table will show more examples of handling specific numbers when dealing with pluralization translation. The table will use the following translation message: Count Result 0 There are no books! 1 You have one, two or three books. 2...

/blog/2016/11/30/laravel-string-pluralization#content-intervals

Specifying every number required for a given translation message can be tedious, or even impossible. However, intervals can be specified to make working with large groups of numbers easier. The syntax for intervals comes directly from the ISO...

/blog/2016/11/30/laravel-string-pluralization#content-using-intervals-with-translation-message

When using intervals with translation messages, the interval appears as the beginning of translation message. Message tags cannot be used when using intervals. The following is an example translation message using intervals: THe following code...

/blog/2016/11/30/laravel-string-pluralization#content-notes-on-decimals

In the previous example, trying to match the number 3.4 will throw an instance of InvalidArgumentException . To match any possible number, including decimals, for the previous translation messages, the explicit number groups must be replaced with...

/blog/2016/12/01/laravel-artisan-command-input-and-command-signatures#content-input-parameters

For example, the following signature could be used to accept a user's first and last name: Since the {firstName} and {lastName} input requirements were defined as parameters and do not define a default value, the command requires that arguments be...

/blog/2016/12/01/laravel-artisan-command-input-and-command-signatures#content-input-parameter-default-values

Command arguments can also have default values. Default values can be specified by assigning the argument a value within the signature. The following would assign the default value Doe to the lastName parameter. If a user does not specify any...

/blog/2016/12/01/laravel-artisan-command-input-and-command-signatures#content-adding-descriptions-to-command-parameters

If we were to display the help information for the hypothetical example:command at this point by adding the -h flag to the command execution: The following information would be included in the output (the "Options" section of the output has been...