this part of the eWAY_XML_PHP.php file:
for ($x=0; $x<count($reqArray[0]); $x++) {
$varvalueArray[strtolower($reqArray[0][$x])] = $reqArray[1][$x];
}
for ($x=0; $x<count($optArray[0]); $x++) {
$varvalueArray[strtolower($optArray[0][$x])] = $optArray[1][$x];
}
for ($x=0; $x<2; $x++) {
$varvalueArray[strtolower($itemArray[0][$x])] = $itemArray[1][$x];
}
is creating a supper array out of the $reqArray, $optArray and $itemArray array's that are created on the confirm page.
This code:
strtolower($reqArray[0][$x])
is used to convert the name used for the array piece on the confirm page to lower case. So the name of each array piece is the lower case version of the name created on the confirm page.
When you are building up the xml, you need to refer to each array piece using the all lower case name.
in other words:
"<eWayCustomerID>" . $varvalueArray["eWayCustomerID"] . "</eWayCustomerID>".
should be:
"<eWayCustomerID>" . $varvalueArray["ewaycustomerid"] . "</eWayCustomerID>".
you can verify the correct names to with this code:
<?php var_dump($varvalueArray); ?>