0

This form posts a transaction, and the server response comes straight back to the browser window as a newline-delimited string.

How do I capture the server response?

The form button: https://www.calligraphydallas.com/stuff/AGI-newline.html

The form code (just save as html, launch it and submit it to see the behavior)

<html>
<form method='Post' action= 'https://www.paymentsgateway.net/cgi-bin/posttest.pl'>
<input type='hidden' name='pg_merchant_id' value='191620'/>
<input type='hidden' name='pg_password' value='PASSWORD02'/>
<input type='hidden' name='pg_transaction_type' value='10'/>
<input type='hidden' name='pg_total_amount' value='11.11'/>
<input type='hidden' name='ecom_payment_card_type' value='visa'/>
<input type='hidden' name='ecom_payment_card_name' value='James D Ivey'/>
<input type='hidden' name='ecom_payment_card_number' value='4111111111111111'/>
<input type='hidden' name='ecom_payment_card_expdate_month' value='08'/>
<input type='hidden' name='ecom_payment_card_expdate_year' value='2020'/>
<input type='hidden' name='ecom_payment_card_verification' value='123'/>
<input type='hidden' name='ecom_billto_postal_name_first' value='Forte'/>
<input type='hidden' name='ecom_billto_postal_name_last' value='Test'/>
<input type='hidden' name='ecom_billto_postal_street_line1' value='500 W Bethany Dr'/>
<input type='hidden' name='ecom_billto_postal_street_line2' value='Suite 200'/>
<input type='hidden' name='ecom_billto_postal_city' value='Allen'/>
<input type='hidden' name='ecom_billto_postal_stateprov' value='TX'/>
<input type='hidden' name='ecom_billto_postal_postalcode' value='75013'/>
<input type='submit' value='Pay Now'/>
</form>
</html>
James
  • 161
  • 1
  • 10

1 Answers1

0

Have you tried using Fiddler ?

clint rock
  • 31
  • 2
  • 10
  • Hi clint rock. Thanks for your reply. Did you submit the form? You will see what I'm talking about. When the form is submitted, the server response displays in the browser window. I want to capture it so that I can parse it into a "pretty" format rather than a delimited string. – James Apr 26 '18 at 03:13
  • I don't know how you are trying to do it, but have a look at this ones: https://stackoverflow.com/questions/374644/how-do-i-capture-response-of-form-submit https://stackoverflow.com/questions/374644/how-do-i-capture-response-of-form-submit – clint rock Apr 26 '18 at 07:30