Commit 079838f2 authored by Nigel McNie's avatar Nigel McNie Committed by Nigel McNie
Browse files

Mark submit elements as such so error messages can be displayed next to

them for ajax errors.
parent eafd06c9
......@@ -39,4 +39,9 @@ function form_render_submit($element, $form) {
. ' value="' . hsc($form->get_value($element)) . '">';
}
function form_render_submit_set_attributes($element) {
$element['ajaxmessages'] = true;
return $element;
}
?>
......@@ -43,4 +43,9 @@ function form_render_submitcancel($element, Form $form) {
return form_render_submit($submitelement, $form) . ' ' . form_render_cancel($cancelelement, $form);
}
function form_render_submitcancel_set_attributes($element) {
$element['ajaxmessages'] = true;
return $element;
}
?>
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