====== setLang ======
{#JAPI Joomla.Framework Document JDocument::setLang #}
Sets the global document language declaration. The default is English.
===== Syntax =====
void setLang ( **$lang** )
| **$lang** | string | is a string containing the new language of the document. This parameter is optional and if omitted defaults to 'en-GB'. |
===== Examples =====
Set the language of the current document.
global $mainframe;
$document =& JFactory::getDocument();
$document->setLang( 'en-US' );
echo "Language: " . $document->getLang();
Might produce:
Language: en-US