Optional processing progressbar for submit buttons
[fa-stable.git] / includes / ui / ui_input.inc
index b775ede018e5b8ae68d83ae3f734f3e812043bc3..65ac068fd5acea5f2850e137973a53e05057a085 100644 (file)
@@ -95,9 +95,10 @@ function hidden($name, $value=null, $echo=true)
 //---------------------------------------------------------------------------------
 //     Submit button.
 //     $async parameter can have 3 values:
+//             null - fallback button not visible in js enabled mode
 //             false - normal submit via form action
 //             true  - when js is on submition via ajax call
-//             null - fallback button not visible in js enabled mode
+//             'process' - ditto with processing indicator in msgbox
 //
 function submit($name, $value, $echo=true, $title=false, $async=false)
 {
@@ -106,7 +107,8 @@ function submit($name, $value, $echo=true, $title=false, $async=false)
        $submit_str = "<input type=\"submit\" class=\""
            .($async ? 'ajaxsubmit' : 'inputsubmit')
                ."\""
-               .($async === null ? (in_ajax() ? " style='display:none;'" : ' fallback="1"' ): '')
+               .($async === null ? (in_ajax() ? " style='display:none;'" : ' aspect="fallback"' ): 
+                       ($async === 'process' ? 'aspect="process"' : '') )
            ." name=\"$name\"  id=\"$name\" value=\"$value\""
            .($title ? " title='$title'" : '')
            .">\n";