_checkOptions example

if (isset($options['currency'])) {
            if (!isset($options['locale'])) {
                $options['locale'] = $this->_options['locale'];
            }

            $options['currency'] = self::getShortName($options['currency']$options['locale']);
            $options['name']     = self::getName($options['currency']$options['locale']);
            $options['symbol']   = self::getSymbol($options['currency']$options['locale']);
        }

        $options = $this->_checkOptions($options) + $this->_options;

        // Format the number         $format = $options['format'];
        $locale = $options['locale'];
        if (empty($format)) {
            $format = Zend_Locale_Data::getContent($locale, 'currencynumber');
        } else if (Zend_Locale::isLocale($format, true, false)) {
            $locale = $format;
            $format = Zend_Locale_Data::getContent($format, 'currencynumber');
        }

        

    public static function setOptions(array $options = array())
    {
        self::$_options = self::_checkOptions($options) + self::$_options;
        return self::$_options;
    }

    /** * Internal function for checking the options array of proper input values * See {@link setOptions()} for details. * * @param array $options Array of options, keyed by option name: format_type = 'iso' | 'php', fix_date = true | false, * locale = Zend_Locale | locale string, precision = whole number between -1 and 30 * @throws Zend_Locale_Exception * @return Options array if no option was given */
Home | Imprint | This part of the site doesn't use cookies.