<?php $api_login_id ='YOUR_API_LOGIN_ID'; $transaction_key ='YOUR_TRANSACTION_KEY'; $amount ="5.99"; $fp_timestamp = time(); $fp_sequence ="123". time();// Can be changed to an invoice or other unique number. $fingerprint =AuthorizeNetSIM_Form::getFingerprint($api_login_id, $transaction_key, $amount, $fp_sequence, $fp_timestamp);?><formmethod='post'action="https://test.authorize.net/gateway/transact.dll"> <input type='hidden' name="x_login" value="<?php echo $api_login_id?>" /> <input type='hidden' name="x_fp_hash" value="<?php echo $fingerprint?>" /> <input type='hidden' name="x_amount" value="<?php echo $amount?>" /> <input type='hidden' name="x_fp_timestamp" value="<?php echo $fp_timestamp?>" /> <input type='hidden' name="x_fp_sequence" value="<?php echo $fp_sequence?>" /> <inputtype='hidden'name="x_version"value="3.1"/><inputtype='hidden'name="x_show_form"value="payment_form"/><inputtype='hidden'name="x_test_request"value="false"/><inputtype='hidden'name="x_method"value="cc"/><inputtype='submit'value="Click here for the secure payment form"/></form>
After customer has completed the form, and the payment is complete, how do i get the response from the form so I could check if payment is complete? Something like:
if($response->approved){ echo "Success! Transaction ID:". $response->transaction_id;}else{ echo "ERROR:". $response->error_message;}
โ07-15-2014 05:22 AM
So you are using SIM?
read about relay response
โ07-15-2014 05:46 AM