diff --git a/source/how_to_use.rst b/source/how_to_use.rst index 4849bbe..ed10e59 100644 --- a/source/how_to_use.rst +++ b/source/how_to_use.rst @@ -158,6 +158,20 @@ The ``language()`` allows you to get a Language model containing valuable inform language()->locale(); + $locale = $ip->language()->locale; // Returns the locale of the recognied language, e.g., 'en_US' + +.. table:: + :width: 100% + :align: center + + +------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | Attributes | Descriptions | + +============+=====================================================================================================================================================================+ + | locale | The locale corresponding to the language recognized in the country | + +------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | all | An array containing all languages spoken within the specified country. | + +------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | officials | An array listing the official languages spoken in the specified country. | + +------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------+