Skip to content

Commit 7b842b5

Browse files
committed
Manage position of captcha modules. Fix responsive of setup page.
1 parent 81790d0 commit 7b842b5

File tree

3 files changed

+18
-3
lines changed

3 files changed

+18
-3
lines changed

htdocs/admin/security_captcha.php

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -120,8 +120,8 @@
120120
closedir($handle);
121121
}
122122
}
123-
asort($arrayhandler);
124-
123+
dol_sort_array($arrayhandler, 'position');
124+
var_dump($arrayhandler);
125125

126126

127127
print '<form action="'.$_SERVER["PHP_SELF"].'" method="POST">';
@@ -134,6 +134,7 @@
134134

135135
print '<br>';
136136

137+
print '<div class="div-table-responsive">';
137138
print '<table class="noborder centpercent">';
138139
print '<tr class="liste_titre">';
139140
print '<td>'.$langs->trans("Captcha").'</td>';
@@ -223,6 +224,8 @@
223224
print '</td></tr>';
224225

225226
print '</table>';
227+
print '</div>';
228+
226229
// Set if a captcha is used on at least one place
227230
$showavailablecaptcha = 0;
228231
if (getDolGlobalString('MAIN_SECURITY_ENABLECAPTCHA')) {
@@ -249,6 +252,7 @@
249252
print '<br>';
250253

251254
// List of all available captcha
255+
print '<div class="div-table-responsive">';
252256
print '<table class="noborder centpercent">';
253257
print '<tr class="liste_titre">';
254258
print '<td colspan="2">'.$langs->trans("Captcha").'</td>';
@@ -289,7 +293,7 @@
289293
}
290294

291295
print '</table>';
292-
296+
print '</div>';
293297
//print $form->buttonsSaveCancel("Modify", '');
294298
}
295299

htdocs/core/modules/security/captcha/modCaptchaStandard.class.php

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,12 @@ class modCaptchaStandard extends ModeleCaptcha
4343
*/
4444
public $picto = 'fa-shield-alt';
4545

46+
/**
47+
* @var int
48+
*/
49+
public $position = 10;
50+
51+
4652
/**
4753
* Constructor
4854
*

htdocs/core/modules/security/captcha/modules_captcha.php

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,11 @@ abstract class ModeleCaptcha
4141
*/
4242
public $version;
4343

44+
/**
45+
* @var int
46+
*/
47+
public $position = 50;
48+
4449
/**
4550
* @var string
4651
*/

0 commit comments

Comments
 (0)