I'm getting the "Warning: Invalid argument supplied for foreach() in" error. I realize that it means that the variable I'm using in my foreach line is not of an array type. However I thought HTTP_POST_VARS was an array. Can anyone see what I'm doing wrong?
class paypal_ipn
{
var $paypal_post_vars = $HTTP_POST_VARS;
function send_response()
{
.....
foreach($this->paypal_post_vars as $key => $value) {
if (@get_magic_quotes_gpc()) {
$value = stripslashes($value);
}
$values[] = "$key" . "=" . urlencode($value);
}
.....