<?php if ($_REQUEST['x_response_code'] == '1') { echo 'Thank you for your payment. Your transaction has been completed, and a receipt for your purchase has been emailed to you.'; } elseif ($_REQUEST['x_response_code'] == '2') { echo 'Your payment was declined'; } elseif ($_REQUEST['x_response_code'] == '3') { echo 'Your payment encountered an error'; } ?>