cancel
Showing results for 
Search instead for 
Did you mean: 

Using the PHP SDK - missing AuthorizeNet.php file

From the http://www.authorize.net/support/DirectPost_guide.pdf Chapter 10, it explains how to set up a test environment, yet many steps are confusing or missing entirely.

 

I assume step 2 and 3 are the same (quite confusing, as step 2 doesn't explain where you get the SDK or if it is different that the SDK in step 3). I skipped step 2, and just downloaded the SDK in step 3 and unzipped it and placed it on the web server).

 

Step 5 is the killer.  "Include anet_php_sdk/AuthorizeNet.php in your project.". This file doesn't reside in the SDK and doesn't explain where you are supposed to get this file.  Once you get it, where should it be placed?  Should you create a directory in on the server "anet_php_sdk" and stick the file there? 

 

The rest of the steps look straight forward, although it woudl have been handy to just have all the files in the project download.

frankvg3
Member
5 REPLIES 5

They haven't  update it after it move to github.

Just read the readme (scroll down) on the https://github.com/AuthorizeNet/sdk-php

RaynorC1emen7
Expert

Thanks for the fast reply. Does that mean it doesn't currently work with PHP?  The readme doesn't say anything about the missing AuthorizeNet.php file (or even reference it).

The new version on github doesn't use that file anymore.

I forgot to ask but maybe other than Github, is there is a better way to test this out on our servers?  Ideally, we'd just like a set of php files that demostrates that it works, perhaps after entry of the API Login ID and transaction key.

Tried the DPM example:

$url             = "http://YOUR_DOMAIN.com/direct_post.php";
$api_login_id    = 'YOUR_API_LOGIN_ID';
$transaction_key = 'YOUR_TRANSACTION_KEY';
$md5_setting     = 'YOUR_MD5_SETTING'; // Your MD5 Setting
$amount          = "5.99";
AuthorizeNetDPM::directPostDemo($url, $api_login_id, $transaction_key, $amount, $md5_setting);

1) The file direct_post.php doesn't exsist anywhere in the GitHub files or sub-directoies

2) What do you put for YOUR_MD5_SETTINGS ?  it wasn't provided with the API Login ID and Transaction Key.
3) Should this code reside in a php file by iteslf, or should it be in HTML code between the body tags (with <?php ?>)?

 

You may want to remove the http://www.authorize.net/support/DirectPost_guide.pdf file with how to use instructions, since they no longer work.