original_string: function get_locale_charset($locale) {
  		$locale = strtolower($locale);
  
  			// exact locale specific charset?
  		if (isset($this->locale_to_charset[$locale])) {
  			return $this->locale_to_charset[$locale];
  		}
  
  			// get modifier
  		list($locale, $modifier) = explode('@', $locale);
  
  			// locale contains charset: use it
  		list($locale, $charset) = explode('.', $locale);
  		if ($charset) {
  			return $this->parse_charset($charset);
  		}
  
  			// modifier is 'euro' (after charset check, because of xx.utf-8@euro)
  		if ($modifier == 'euro') {
  			return 'iso-8859-15';
  		}
  
  			// get language
  		list($language, $country) = explode('_', $locale);
  		if (isset($this->lang_to_script[$language])) {
  			$script = $this->lang_to_script[$language];
  		}
  
  		if (TYPO3_OS == 'WIN') {
  			$cs = $this->script_to_charset_windows[$script] ? $this->script_to_charset_windows[$script] : 'windows-1252';
  		} else {
  			$cs = $this->script_to_charset_unix[$script] ? $this->script_to_charset_unix[$script] : 'utf-8';
  		}
  
  		return $cs;
  	}
code: function get_locale_charset($locale) {
  		$locale = strtolower($locale);
  
  			// exact locale specific charset?
  		if (isset($this->locale_to_charset[$locale])) {
  			return $this->locale_to_charset[$locale];
  		}
  
  			// get modifier
  		list($locale, $modifier) = explode('@', $locale);
  
  			// locale contains charset: use it
  		list($locale, $charset) = explode('.', $locale);
  		if ($charset) {
  			return $this->parse_charset($charset);
  		}
  
  			// modifier is 'euro' (after charset check, because of xx.utf-8@euro)
  		if ($modifier == 'euro') {
  			return 'iso-8859-15';
  		}
  
  			// get language
  		list($language, $country) = explode('_', $locale);
  		if (isset($this->lang_to_script[$language])) {
  			$script = $this->lang_to_script[$language];
  		}
  
  		if (TYPO3_OS == 'WIN') {
  			$cs = $this->script_to_charset_windows[$script] ? $this->script_to_charset_windows[$script] : 'windows-1252';
  		} else {
  			$cs = $this->script_to_charset_unix[$script] ? $this->script_to_charset_unix[$script] : 'utf-8';
  		}
  
  		return $cs;
  	}
code_tokens: function get_locale_charset ( $ locale ) { $ locale = strtolower ( $ locale ) ; // exact locale specific charset? if ( isset ( $ this -> locale_to_charset [ $ locale ] ) ) { return $ this -> locale_to_charset [ $ locale ] ; } // get modifier list ( $ locale , $ modifier ) = explode ( '@' , $ locale ) ; // locale contains charset: use it list ( $ locale , $ charset ) = explode ( '.' , $ locale ) ; if ( $ charset ) { return $ this -> parse_charset ( $ charset ) ; } // modifier is 'euro' (after charset check, because of xx.utf-8@euro) if ( $ modifier == 'euro' ) { return 'iso-8859-15' ; } // get language list ( $ language , $ country ) = explode ( '_' , $ locale ) ; if ( isset ( $ this -> lang_to_script [ $ language ] ) ) { $ script = $ this -> lang_to_script [ $ language ] ; } if ( TYPO3_OS == 'WIN' ) { $ cs = $ this -> script_to_charset_windows [ $ script ] ? $ this -> script_to_charset_windows [ $ script ] : 'windows-1252' ; } else { $ cs = $ this -> script_to_charset_unix [ $ script ] ? $ this -> script_to_charset_unix [ $ script ] : 'utf-8' ; } return $ cs ; }
docstring: Get the charset of a locale.
  
  ln			language
  ln_CN		 language / country
  ln_CN.cs	  language / country / charset
  ln_CN.cs@mod  language / country / charset / modifier
  
  @param	string		Locale string
  @return	string		Charset resolved for locale string
  @author	Martin Kutschker <martin.t.kutschker@blackbox.net>
docstring_tokens: Get the charset of a locale .