getCurrencyFor() public static method

Returns the currency of the site with the specified ID.
public static getCurrencyFor ( integer $idsite ) : string
$idsite integer The site ID.
return string
Exemplo n.º 1
0
 /**
  * Returns the currency symbol for a site.
  *
  * @param int $idSite The ID of the site to return the currency symbol for.
  * @return string eg, `'$'`.
  * @api
  */
 public static function getCurrencySymbol($idSite)
 {
     $symbols = self::getCurrencyList();
     $currency = Site::getCurrencyFor($idSite);
     if (isset($symbols[$currency])) {
         return $symbols[$currency][0];
     }
     return '';
 }