|
|
@ -5,32 +5,30 @@ $lang = substr $lang, 0, 2; |
|
|
|
|
|
|
|
|
|
|
|
$OUT .=<<"EOF"; |
|
|
|
$OUT .=<<"EOF"; |
|
|
|
|
|
|
|
|
|
|
|
if (!function_exists('hook_get_auth_webserver_profile')){ |
|
|
|
function hook_get_auth_webserver_profile(\$user_name) { |
|
|
|
function hook_get_auth_webserver_profile(\$user_name) { |
|
|
|
if (!isset(\$_SERVER['REMOTE_USER'])){ |
|
|
|
if (!isset(\$_SERVER['REMOTE_USER'])){ |
|
|
|
return false; |
|
|
|
return false; |
|
|
|
} |
|
|
|
} |
|
|
|
\$login = \$_SERVER['REMOTE_USER']; |
|
|
|
\$login = \$_SERVER['REMOTE_USER']; |
|
|
|
if (isset(\$_SERVER['HTTP_USER_NAME'])){ |
|
|
|
if (isset(\$_SERVER['HTTP_USER_NAME'])){ |
|
|
|
\$name = \$_SERVER['HTTP_USER_NAME']; |
|
|
|
\$name = \$_SERVER['HTTP_USER_NAME']; |
|
|
|
} |
|
|
|
} |
|
|
|
else{ |
|
|
|
else{ |
|
|
|
\$name = \$login; |
|
|
|
\$name = \$login; |
|
|
|
} |
|
|
|
} |
|
|
|
if (isset(\$_SERVER['HTTP_USER_EMAIL'])){ |
|
|
|
if (isset(\$_SERVER['HTTP_USER_EMAIL'])){ |
|
|
|
\$email = \$_SERVER['HTTP_USER_EMAIL']; |
|
|
|
\$email = \$_SERVER['HTTP_USER_EMAIL']; |
|
|
|
} |
|
|
|
} |
|
|
|
else{ |
|
|
|
else{ |
|
|
|
\$email = \$login . '\@$DomainName'; |
|
|
|
\$email = \$login . '\@$DomainName'; |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
return Array( |
|
|
|
|
|
|
|
'full_name' => \$name, |
|
|
|
|
|
|
|
'email' => \$email, |
|
|
|
|
|
|
|
'lang' => '$lang', |
|
|
|
|
|
|
|
'htmleditormode' => 'inline', |
|
|
|
|
|
|
|
'templatelist' => 'default,basic,MyOrgTemplate', |
|
|
|
|
|
|
|
); |
|
|
|
|
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
return Array( |
|
|
|
|
|
|
|
'full_name' => \$name, |
|
|
|
|
|
|
|
'email' => \$email, |
|
|
|
|
|
|
|
'lang' => '$lang', |
|
|
|
|
|
|
|
'htmleditormode' => 'inline', |
|
|
|
|
|
|
|
'templatelist' => 'default,basic,MyOrgTemplate', |
|
|
|
|
|
|
|
); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
if (!function_exists('hook_get_auth_webserver_permissions')){ |
|
|
|
if (!function_exists('hook_get_auth_webserver_permissions')){ |
|
|
|