cancel
Showing results for 
Search instead for 
Did you mean: 

Yet another dreaded Error Code 13 for DPM in Perl

I'm trying to implement DPM in Perl.  I've cobbled a skeletal test bed just to make sure I have the basic functionality before I wire it into the real app.  Unfortunately, I can't get past error 13.  Here is the generated HTML:

<!DOCTYPE html
	PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
	 "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" lang="en-US" xml:lang="en-US">
<head>
<title>Confirmation page</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
</head>
<body>

<h1>Confirm amount</h1>
<p>Confirm payment of $5.99 USD.</p>
<form method="post" action="https://test.authorize.net/gateway/transact.dll" enctype="multipart/form-data">

<input type="hidden" name="x_method" value="CC"  />

<input type="hidden" name="x_type" value="AUTH_CAPTURE"  />
<input type="hidden" name="x_card_num" value="4007000000027"  />
<input type="hidden" name="x_exp_date" value="11/12"  />
<input type="hidden" name="x_card_code" value="782"  />
<input type="hidden" name="x_amount" value="5.99"  />
<input type="hidden" name="x_fp_sequence" value="428"  />
<input type="hidden" name="x_fp_timestamp" value="1325191206"  />
<input type="hidden" name="x_fp_hash" value="51a096dec8f280e76dc7c49f6aed6654"  />
<input type="hidden" name="x_login" value="xxxxxxxxxxx"  />
<input type="hidden" name="x_relay_response" value="TRUE"  />
<input type="hidden" name="x_relay_url" value="http://my.domain.com/cgi-local/relay_response.cgi"  />
<input type="hidden" name="x_version" value="3.1"  />
<input type="submit" name=".submit" />
</form>

</body>
</html>

 I'm using my test API login (just got it yesterday), and the transaction key I was issued at that time.  Today, I got a new transaction key and am still getting the same result.

I cobbled together some Perl code to test the generation of the fingerprint, and did the same in PHP using the downloaded PHP API.  They both generate the same fingerprint, so I believe that part is correct.

What's missing from this picture?

Thanks for your help.

-- Bob.

bobcatos
Member
1 ACCEPTED SOLUTION

Accepted Solutions

Hmm.  That's interesting.  Whodathunkit.  Okay, I added the "-no_xhtml" pragma to the loading of the CGI module and now it generates HTML v4.01 code and the form tag is generated with the

enctype="application/x-www-form-urlencoded

attribute. Now I no longer get the error 13. Thanks for the clue.

View solution in original post

4 REPLIES 4

It there a reason for enctype="multipart/form-data" on the form post?

RaynorC1emen7
Expert

That's what the Perl CGI module generates as part of the form tag.  Why?  Is that a problem?

 

It might be messing with the post data as it look like it is for binary data.

Hmm.  That's interesting.  Whodathunkit.  Okay, I added the "-no_xhtml" pragma to the loading of the CGI module and now it generates HTML v4.01 code and the form tag is generated with the

enctype="application/x-www-form-urlencoded

attribute. Now I no longer get the error 13. Thanks for the clue.