Magento Success.phtml Html Encoding Everything
===

Having a problem placing analytics code on my success.phtml page with magento. For some reason, whenever I echo any string with a "&" in it, Magento encodes it and prints out "&amp;", even when it is part of an IMG's src url. For example, this code :

<?php 
	echo '<img src="zmam=775xxxxx&zmas=1&zmaq=N&quantity=' . $item->getQtyOrdered() . '&pcode=' . $catalog_number . '&zman=' . $lastOrderId . '&zmat=' . $_subtotal . '" width=0 height=0 border=0>';
?>

Prints out this on the receipt page:
<img src="zmam=775xxxxx&amp;zmas=1&amp;zmaq=N&amp;quantity=1.0000&amp;pcode=&amp;zman=Z77436&amp;zmat=8.9500" width="0" height="0" border="0">


This is true for every echo on the page. I can not track anything with a number of different Analytics providers currently. I have googled for awhile now and can not find anything on the subject- so any input at all would be appreciated.

Thank you.