Skip to content
Browse files

added function lesson_clean_data_submitted(), this cleans the object …

…made from data_submitted() function
  • Loading branch information...
1 parent eb65aeb commit 57bfe93dca64d60bf8ec1cd7dbfe10b4bf63465f michaelpenne committed Jan 26, 2005
Showing with 20 additions and 0 deletions.
  1. +20 −0 mod/lesson/locallib.php
View
20 mod/lesson/locallib.php
@@ -1131,6 +1131,26 @@ function lesson_check_nickname($name) {
}
return true;
}
+
+/*******************************************************************/
+function lesson_clean_data_submitted() {
+//
+//
+ $form = data_submitted();
+ foreach ($form as $valuename => $formvalue) {
+ if (is_array($formvalue)) {
+ foreach ($formvalue as $index => $formsubvalue) {
+ $formvalue[$index] = clean_param($formsubvalue, PARAM_CLEAN);
+ }
+ $form->$valuename = $formvalue;
+ } else {
+ $form->$valuename = clean_param($formvalue, PARAM_CLEAN);
+ }
+ }
+
+ return $form;
+}
+
/// CDC-FLAG ///
?>

0 comments on commit 57bfe93

Please sign in to comment.
Something went wrong with that request. Please try again.