for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
/**
* Translator.php - Trait for translation functions
*
* Make functions of the utils classes available to Jaxon classes.
* @package jaxon-core
* @author Thierry Feuzeu <[email protected]>
* @copyright 2016 Thierry Feuzeu <[email protected]>
* @license https://opensource.org/licenses/BSD-3-Clause BSD 3-Clause License
* @link https://github.com/jaxon-php/jaxon-core
*/
namespace Jaxon\Features;
trait Translator
{
* Get a translated string
* @param string $sText The key of the translated string
* @param string $aPlaceHolders The placeholders of the translated string
* @param string $sLanguage The language of the translated string
* @return string The translated string
public function trans($sText, array $aPlaceHolders = [], $sLanguage = null)
return jaxon()->di()->getTranslator()->trans($sText, $aPlaceHolders, $sLanguage);
}