<?php
Class Zend_View_Helper_TrueLabel extends Zend_View_Helper_Abstract
{
    public function __construct()
    {
        
    }

    public function TrueLabel($list, $name)
    {
        try {
            return (self::GetTrueLabel($list, $name));
        } catch (Exception $e) {
            echo 'Aucun label : ' . $e;
        }
    }
    
    private function GetTrueLabel($list, $name)
    {
        if(isset($list)) {
            foreach ($list as $nameLabel => $label)
            {
                if ($nameLabel == $name)
                    return ($label);
            }
        }
        return ($name);
    }
}