Commit 34d825e2 authored by Nigel McNie's avatar Nigel McNie
Browse files

Get the tabindex for the captcha from the form correctly so it will always work.

parent 56f588f0
......@@ -27,7 +27,7 @@
function pieform_element_captcha(Pieform $form, $element) {
$id = $form->get_name() . '_' . $element['name'];
$image = '<img src="' . get_config('wwwroot') . 'captcha.php?name=' . $id . '" alt="' . get_string('captchaimage') . '" style="padding: 2px 0;"><br>';
$input = '<input type="text" class="text required" id="' . $id . '" name="' . $element['name'] . '" style="width: 137px;" tabindex="4">';
$input = '<input type="text" class="text required" id="' . $id . '" name="' . $element['name'] . '" style="width: 137px;" tabindex="' . $form->get_property('tabindex') . '">';
return $image . ' ' . $input;
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment