Subversion-Projekte lars-tiefland.em_wm

Revision

Revision 66 | Revision 71 | Zur aktuellen Revision | Details | Vergleich mit vorheriger | Letzte Änderung | Log anzeigen | RSS feed

Revision Autor Zeilennr. Zeile
3 lars 1
<?
66 lars 2
 
64 lars 3
	//DB Connection
4
	require_once("connect.php");
5
 
6
	//PEAR Packages
27 lars 7
	require_once("Text/Password.php");
8
	require_once("I18Nv2.php");
44 lars 9
	require_once("Auth.php");
60 lars 10
	require_once("Mail.php");
11
	require_once("Translation2.php");
64 lars 12
	require_once("Log.php");
13
 
14
	$params_tr["strings_default_table"]="i18n_%s";
15
	$params_tr["string_text_col"]="string";
16
	$tr=& Translation2::factory("db",$db,$params_tr);
44 lars 17
 
60 lars 18
	$mail=	& Mail::factory("mail",array());
64 lars 19
 
44 lars 20
	//Smarty
27 lars 21
	require_once("libs/Smarty.class.php");
44 lars 22
	$smarty=new Smarty;
66 lars 23
	$smarty->assign("error",false);
67 lars 24
	$smarty->assign("save",false);
25
	$smarty->assign("upd",false);
66 lars 26
	$smarty->assign("meld","");
67 lars 27
	$smarty->assign("mode","");
66 lars 28
	$smarty->assign("db_meld","");
29
	$smarty->assign("u_type",0);
67 lars 30
	$smarty->assign("id",0);
66 lars 31
	$smarty->assign("u_name","");
44 lars 32
	//
54 lars 33
	require_once("user.class.php");
27 lars 34
	require_once("config.php");
44 lars 35
	$config=new Config();
66 lars 36
	$year=$config->year;
37
	$loc=&I18Nv2::createLocale("en_US");
44 lars 38
	require_once("functions.php");
16 lars 39
	//
27 lars 40
	require_once("spiele.php");
41
	require_once("teams.php");
42
	require_once("orte.php");
43
	require_once("gruppen.php");
44
	require_once("types.php");
16 lars 45
 
17 lars 46
	$smarty->assign("version", $config->version);
27 lars 47
	$smarty->assign("logo", "images/$config->logo");
48
	$max_anz=$config->max_anz;
64 lars 49
	$u=new User("","");
50
	$tr =& $tr->getDecorator('Lang'); $tr->setOption('fallbackLang', 'en');
63 lars 51
	$tr->setPageID("common");
64 lars 52
	$tr->setLang($u->u_lang);
62 lars 53
	$common=$tr->getPage();
54
	foreach ($common as $key => $value)
55
	{
56
		$smarty->assign(strtoupper("L_$key"),$value);
57
	}
64 lars 58
	if (!defined("IN_ADMIN"))
59
	{
60
		$show=false;
61
	}
62
	else
63
	{
64
		$show=true;
65
	}
66
	$a=user_login($show);
67
	if($a->getUserName())
68
	{
69
		$u=$u->UserData($a->getUserName());
70
	}
67 lars 71
	$u_loc=($u->u_lang=="de")?"de_DE":"en_US";
64 lars 72
	$tr->setPageID("common");
73
	$tr->setLang($u->u_lang);
74
	$common=$tr->getPage();
66 lars 75
	$type=$common["$config->type"];
64 lars 76
	foreach ($common as $key => $value)
77
	{
78
		$smarty->assign(strtoupper("L_$key"),$value);
79
	}
67 lars 80
	$loc=&I18Nv2::createLocale("$u_loc");
66 lars 81
	$date=$loc->formatDateTime(time());
82
	$smarty->assign("date",$date);
83
	$smarty->assign("year",$year);
84
	$smarty->assign("L_TYPE",$type);
64 lars 85
	$logger=create_logger();
3 lars 86
?>