CBlogSmile :: getSmiles: Bitrix method

      
<?php 
//  CBlogSmile :: getSmiles()
//  /dist/bitrix/modules/blog/general/smile.php:86

    
public static function getSmiles($type$lang)
    {
        
$type = ($type == "I" CSmile::TYPE_ICON CSmile::TYPE_SMILE);
        
$key "new_".$type."_".$lang;

        if (!
array_key_exists($keyself::$smiles))
        {
            
$smiles CSmile::getByGalleryId($typeCOption::GetOptionInt("blog""smile_gallery_id"0), $lang);
            
$result = array();
            foreach (
$smiles as $smile)
            {
                if (
$smile['HIDDEN'] == 'Y')
                    continue;

                
$result[] = array(
                    
'SET_ID' => $smile['SET_ID'],
                    
'NAME' => $smile['NAME'],
                    
'IMAGE' => ($smile['TYPE'] == CSmile::TYPE_SMILE CSmile::PATH_TO_SMILE CSmile::PATH_TO_ICON).$smile["SET_ID"]."/".$smile["IMAGE"],
                    
'TYPING' => $smile['TYPING'],
                    
'WIDTH' => $smile['IMAGE_WIDTH'],
                    
'HEIGHT' => $smile['IMAGE_HEIGHT'],
                );
            }
            
self::$smiles[$key] = $result;
        }
        return 
self::$smiles[$key];
    }