Automatic language detection

Added automatic language detection based on HTTP_ACCEPT_LANGUAGE
header. New function _translate, that translates string to required
language.
New file: setlang.php?l=language_code - sets session language.
This commit is contained in:
ZonD80 2013-01-25 13:54:01 +04:00
commit c8e0ca45fb
7 changed files with 79 additions and 28 deletions

View file

@ -1,5 +1,11 @@
<?php
session_start();
define('NO_AUTH_REQUIRED',true);
include($_SERVER['DOCUMENT_ROOT']."/inc/main.php");
if (isset($_SESSION['user'])) {
header("Location: /list/user");
} else {