the $HTTP_POST_VARS array is actually an associative array, which means its keys are strings, not numbers like normal arrays. To access the second element you would have to use the string of the form variable you are submitting, i.e.
$HTTP_POST_VARS["variable2"];
To loop through them, you would use PHP's foreach:
foreach($HTTP_POST_VARS AS $post_var_name => $post_var_value) {
echo $post_var_value;
}
Hope that helps.
Chris