/** * Gets the form inputs and validates it's format and dataype and if it's required or not * @param form_name The name of the form * @param exclude_columns array of columns names that you dont want to validate * @return boolean */ public static function ValidRequest($form_name, $exclude_columns = null) { $inputs = SystemQueries::form_input_structure($form_name); foreach ($inputs as $input) { if ($exclude_columns == null || !in_array($input->input_name, $exclude_columns)) { self::Set($input); self::Nullable($input); if ($input->input_type != "file") { if (self::VarcharBlobText($input)) { continue; } else { if (self::Integer($input)) { continue; } else { if (self::DoubleFloat($input)) { continue; } else { return false; } } } } } } return true; }