solo
collection of class for development single, (*1)
, (*2)
name: Wallace Rio
email: wallrio@gmail.com
site: wallrio.com, (*3)
page project: solo.wallrio.com, (*4)
Installation:
Este pacote esta disponivel via Composer., (*5)
Using:
$translation = new \WallRio\Solo\Translation();
echo $translation->go('Text to translate');
Functions available:
-
go( Source = STRING , goSimilar = INTEGER , showSimilar = BOOLEAN , langaguePrefixFrom = STRING, langaguePrefixTo = STRING)
description: This method represents the last text parameter., (*6)
return: (string), (*7)
example:, (*8)
$translation = new \WallRio\Solo\Translation();
echo $translation->go('Text to translate');
Example outlet: 'Texto para traduzir', (*9)
-
goSimilar( Source = STRING )
description: This method displays the translations similar to a word., (*10)
return: (string), (*11)
example:, (*12)
$translation = new \WallRio\Solo\Translation();
echo $translation->goSimilar('home');
Example outlet: 'casa,inicio,moradia', (*13)
-
stylefont( STYLE = STRING )
description: This method is used to format globally as the translated text., (*14)
return: (void) este método não tem retorno, (*15)
example:, (*16)
$translation = new \WallRio\Solo\Translation();
$translation->stylefont('ucfirst:true;ucwords:false');
description: This method is used to list the languages available., (*17)
return: (array), (*18)
example:, (*19)
$translation = new \WallRio\Solo\Translation();
$translation->listLanguages();
var_dump($translation);
-
setLanguageTo( langaguePrefix = STRING )
description: This method is used to choose the target language of the translation., (*20)
return: (void), (*21)
example:, (*22)
$translation = new \WallRio\Solo\Translation();
$translation->setLanguageTo('ptbr');
-
setLanguageFrom( langaguePrefix = STRING )
description: This method is used to choose the source language of the translation., (*23)
return: (void), (*24)
example:, (*25)
$translation = new \WallRio\Solo\Translation();
$translation->setLanguageFrom('ptbr');
description: This method is used to capture the name of the target language translation., (*26)
return: (string), (*27)
example:, (*28)
$translation = new \WallRio\Solo\Translation();
echo $translation->getLanguageNameTo();