mirror of
https://github.com/Dolibarr/dolibarr.git
synced 2025-12-15 14:01:22 +01:00
Dbut ajout d'un code captcha
This commit is contained in:
@@ -1170,6 +1170,7 @@ function info_admin($texte)
|
||||
function dol_loginfunction($notused,$pearstatus)
|
||||
{
|
||||
global $langs,$conf,$mysoc;
|
||||
|
||||
$langs->load("main");
|
||||
$langs->load("other");
|
||||
|
||||
@@ -1223,10 +1224,17 @@ function dol_loginfunction($notused,$pearstatus)
|
||||
print '<body class="body" onload="donnefocus();">';
|
||||
|
||||
// Start Form
|
||||
print '<form id="login" name="login" method="post" action="';
|
||||
print $_SERVER['PHP_SELF'];
|
||||
print $_SERVER["QUERY_STRING"]?'?'.$_SERVER["QUERY_STRING"]:'';
|
||||
print '">';
|
||||
if ($conf->global->MAIN_SECURITY_ENABLECAPTCHA)
|
||||
{
|
||||
print '<form id="login" name="login" method="post" action="'.DOL_URL_ROOT.'/verifier.php?'.SID.'">';
|
||||
}
|
||||
else
|
||||
{
|
||||
print '<form id="login" name="login" method="post" action="';
|
||||
print $_SERVER['PHP_SELF'];
|
||||
print $_SERVER["QUERY_STRING"]?'?'.$_SERVER["QUERY_STRING"]:'';
|
||||
print '">';
|
||||
}
|
||||
|
||||
// Table 1
|
||||
print '<table cellpadding="0" cellspacing="0" border="0" align="center" width="450">';
|
||||
@@ -1272,12 +1280,24 @@ function dol_loginfunction($notused,$pearstatus)
|
||||
print '<td rowspan="2"><img title="'.$title.'" src="'.$urllogo.'"';
|
||||
if ($width) print ' width="'.$width.'"';
|
||||
print '></td>';
|
||||
|
||||
print '</tr>';
|
||||
|
||||
print '<tr><td align="left" valign="top"> <b>'.$langs->trans("Password").'</b> </td>';
|
||||
print '<td valign="top" nowrap="nowrap"><input name="password" class="flat" type="password" size="15" maxlength="30" tabindex="2">';
|
||||
print '</td></tr>';
|
||||
|
||||
print '<tr><td colspan="3"> </td></tr>'."\n";
|
||||
|
||||
// Code de s<>curit<69>
|
||||
if ($conf->global->MAIN_SECURITY_ENABLECAPTCHA)
|
||||
{
|
||||
$cryptinstall = DOL_DOCUMENT_ROOT.'/includes/cryptographp/cryptographp.fct.php';
|
||||
include_once $cryptinstall;
|
||||
print '<tr><td align="left"> <b>'.$langs->trans("Code").'</b></td>';
|
||||
print '<td><input type="text" size="15" maxlength="10" name="code"></td>';
|
||||
dsp_crypt(0,1);
|
||||
print '</tr>';
|
||||
}
|
||||
|
||||
print '<tr><td colspan="3" style="text-align:center;"><br>';
|
||||
print '<input type="submit" class="button" value=" '.$langs->trans("Connection").' " tabindex="4" />';
|
||||
|
||||
Reference in New Issue
Block a user