Wiki source code of Administration
Last modified by superadmin on 2025/05/22 17:44
Hide last authors
| author | version | line-number | content |
|---|---|---|---|
| |
1.1 | 1 | {{velocity}} |
| 2 | |||
| 3 | {{html clean="false"}} | ||
| 4 | <form method="post" action="${xwiki.getURL('XWiki.Captcha.Configuration', 'save')}" class='xform'> | ||
| 5 | <div class="hidden"> | ||
| 6 | <input type='hidden' name='form_token' value="$!{services.csrf.getToken()}" /> | ||
| 7 | <input type='hidden' name='xredirect' value="$xwiki.getRequestURL()" /> | ||
| 8 | </div> | ||
| 9 | <dl> | ||
| 10 | <dt> | ||
| 11 | <label for="XWiki.Captcha.ConfigurationClass_0_captcha">$escapetool.xml($services.localization.render('captcha.admin.defaultCaptchaName.label'))</label> | ||
| 12 | <span class='xHint'>$escapetool.xml($services.localization.render('captcha.admin.defaultCaptchaName.hint'))</span> | ||
| 13 | </dt> | ||
| 14 | <dd> | ||
| 15 | <select name="XWiki.Captcha.ConfigurationClass_0_captcha" id="XWiki.Captcha.ConfigurationClass_0_captcha"> | ||
| 16 | #foreach ($captchaName in $services.captcha.captchaNames) | ||
| 17 | <option value="${captchaName}" #if($captchaName == $services.captcha.defaultCaptchaName)selected='selected'#end> | ||
| 18 | $escapetool.xml($services.localization.render("captcha.${captchaName}")) | ||
| 19 | </option> | ||
| 20 | #end | ||
| 21 | </select> | ||
| 22 | </dd> | ||
| 23 | </dl> | ||
| 24 | <div class='buttonwrapper'> | ||
| 25 | <input value="$escapetool.xml($services.localization.render('admin.save'))" class='button' type='submit'> | ||
| 26 | </div> | ||
| 27 | </form> | ||
| 28 | {{/html}} | ||
| 29 | |||
| 30 | (% class='row' %)((( | ||
| 31 | (% class='col-xs-12 col-lg-7' %)((( | ||
| 32 | #set ($captchaImplementationAdministrations = $services.uix.getExtensions('org.xwiki.captcha', {'select' : "$!{services.captcha.defaultCaptchaName}"})) | ||
| 33 | #if ($captchaImplementationAdministrations.size() > 0) | ||
| 34 | === $services.localization.render('captcha.admin.configure.title', $services.rendering.resolveSyntax('xwiki/2.1'), [$services.localization.render("captcha.${services.captcha.defaultCaptchaName}")]) === | ||
| 35 | $services.rendering.render($captchaImplementationAdministrations[0].execute(), $doc.syntax) | ||
| 36 | #end | ||
| 37 | ))) | ||
| 38 | (% class='col-xs-12 col-lg-5 well' %)((( | ||
| 39 | === $services.localization.render('captcha.admin.sample.title', $services.rendering.resolveSyntax('xwiki/2.1')) === | ||
| 40 | |||
| 41 | $services.localization.render('captcha.admin.sample.description', $services.rendering.resolveSyntax('xwiki/2.1')) | ||
| 42 | |||
| 43 | {{html clean='false'}} | ||
| 44 | <div class='xform'> | ||
| 45 | $services.captcha.default.display() | ||
| 46 | </div> | ||
| 47 | {{/html}} | ||
| 48 | ))) | ||
| 49 | ))) | ||
| 50 | {{/velocity}} |