Line 2... |
Line 2... |
2 |
function xlat($filter,$login,$config)
|
2 |
function xlat($filter,$login,$config)
|
3 |
{
|
3 |
{
|
4 |
$string = $filter;
|
4 |
$string = $filter;
|
5 |
if ($filter != ''){
|
5 |
if ($filter != ''){
|
6 |
$string = preg_replace('/%u/',$login,$string);
|
6 |
$string = preg_replace('/%u/',$login,$string);
|
7 |
$string = preg_replace('/%U/',$_SERVER["PHP_AUTH_USER"],$string);
|
7 |
$string = preg_replace('/%U/',$_SERVER["REMOTE_USER"],$string);
|
8 |
$string = preg_replace('/%ma/',$mappings[$http_user]['accounting'],$string);
|
8 |
$string = preg_replace('/%ma/',$mappings[$http_user]['accounting'],$string);
|
9 |
$string = preg_replace('/%mu/',$mappings[$http_user]['userdb'],$string);
|
9 |
$string = preg_replace('/%mu/',$mappings[$http_user]['userdb'],$string);
|
10 |
$string = preg_replace('/%mn/',$mappings[$http_user]['nasdb'],$string);
|
10 |
$string = preg_replace('/%mn/',$mappings[$http_user]['nasdb'],$string);
|
11 |
$string = preg_replace('/%mN/',$mappings[$http_user]['nasadmin'],$string);
|
11 |
$string = preg_replace('/%mN/',$mappings[$http_user]['nasadmin'],$string);
|
12 |
}
|
12 |
}
|