When trying to setup authorize.net I get this error

Warning: Variable passed to each() is not an array or object in /admin/modules.php on line 56

Warning: Cannot modify header information - headers already sent by (output started at /admin/modules.php:56) in /admin/includes/functions/general.php on line 21


line 56 on modules.php

while (list($key, $value) = each($_POST['configuration'])) {

line 21 on general.php

header('Location: ' . $url);


Not sure what is causing the problem by examining the code, anyone have any ideas?