Ver código fonte

change the name of files in classes for gettext (multi languages)

Victor De la Rocha 17 anos atrás
pai
commit
009d010937
3 arquivos alterados com 1 adições e 18 exclusões
  1. 0 0
      classes/gettext.class.php
  2. 1 18
      classes/lang.functions.php
  3. 0 0
      classes/streams.class.php

classes/gettext.php → classes/gettext.class.php Ver arquivo


classes/lang.php → classes/lang.functions.php Ver arquivo

@@ -1,28 +1,11 @@
1
-<?
2
-$idiomas = array();
3
-$idiomas['es_MX'] = "Espa&ntilde;ol de M&eacute;xico";
4
-$idiomas['en'] = "English";
5
-
6
-function esIdioma($test) {
7
-	global $idiomas;
8
-	if (isset($idiomas[$test]))
9
-		return true;
10
-	else
11
-		return false;
12
-}
13
-
1
+<?php
14 2
 function initIdioma($lang = "en") {
15 3
 	global $locale, $l10n;
16 4
 
17
-	if (!esIdioma($locale) && esIdioma($lang)) {
18
-		$locale = $lang;
19
-	}
20
-
21 5
 	$input = new FileReader(dirname(__FILE__)."/../idiomas/". $locale ."/lang.mo");
22 6
 	$l10n = new gettext_reader($input);
23 7
 }
24 8
 
25
-// Standard wrappers for xgettext
26 9
 function __($text) {
27 10
 	global $l10n;
28 11
 	return $l10n->translate($text);

classes/streams.php → classes/streams.class.php Ver arquivo