Skip to content

Commit

Permalink
docs: add/update description for lang()
Browse files Browse the repository at this point in the history
  • Loading branch information
kenjis committed Apr 28, 2024
1 parent fe86be5 commit d1631d6
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 4 deletions.
10 changes: 6 additions & 4 deletions user_guide_src/source/general/common_functions.rst
Original file line number Diff line number Diff line change
Expand Up @@ -106,13 +106,15 @@ Service Accessors

.. php:function:: lang($line[, $args[, $locale]])
:param string $line: The line of text to retrieve
:param string $line: The language filename and the key of the text to retrieve.
:param array $args: An array of data to substitute for placeholders.
:param string $locale: Specify a different locale to be used instead of default one.
:param string $locale: Specify a different locale to be used instead of the current locale.
:returns: The text in the language file
:rtype: list<string>|string

Retrieves a locale-specific file based on an alias string.
Retrieves text from the language files.

For more information, see the :doc:`Localization </outgoing/localization>` page.
For more information, see the :ref:`language-localization`.

.. php:function:: model($name[, $getShared = true[, &$conn = null]])
Expand Down
2 changes: 2 additions & 0 deletions user_guide_src/source/outgoing/localization.rst
Original file line number Diff line number Diff line change
Expand Up @@ -130,6 +130,8 @@ Alternatively, you can use the :doc:`Services class </concepts/services>` to ret

.. literalinclude:: localization/006.php

.. _language-localization:

*********************
Language Localization
*********************
Expand Down

0 comments on commit d1631d6

Please sign in to comment.