Jump to content

Ship_to Information Not Passing To Authorize.net


Guest mhilliard

Recommended Posts

Guest mhilliard

I'm stumped.

I've been fiddling with the form.inc.php information, trying to get the Shipping information to pass through the gateway for Authorize.net to use in their confirmation emails to the customer. None of the customers are seeing the shipping address when they place their orders, though we can see the data on the order summaries in CubeCart.

I've modified the form.inc.php script to look like this for the delivery information:

		$authnet_values				= array

		(

			"x_invoice_num"			=> $orderSum['cart_order_id'],

			"x_password"			=> $auth_net_password,

			"x_login"				=> $auth_net_login_id,

			"x_version"				=> "3.1",

			"x_delim_char"			=> "|",

			"x_delim_data"			=> "TRUE",

			"x_url"					=> "FALSE",

			"x_type"				=> "AUTH_CAPTURE",

			"x_method"				=> "CC",

			"x_tran_key"			=> $auth_net_tran_key,

			"x_relay_response"		=> "FALSE",

			"x_card_num"			=> trim($_POST["cardNumber"]),

			"x_card_code"			=> trim($_POST['cvv']),

			"x_exp_date"			=> trim($_POST["expirationMonth"]).trim($_POST["expirationYear"]),

			"x_description"			=> "Payment for order number ".$orderSum['cart_order_id'],

			"x_amount"				=> $orderSum['prod_total'],

			"x_first_name"			=> trim($_POST["firstName"]),

			"x_last_name"			=> trim($_POST["lastName"]),

			"x_address"				=> trim($_POST["addr1"]).' '.trim($_POST["addr2"]),

			"x_city"				=> trim($_POST["city"]),

			"x_state"				=> trim($_POST["state"]),

			"x_zip"					=> trim($_POST["postalCode"]),

			"x_country"		=> trim($_POST["country"]),

			"x_ship_to_first_name"  => $basket['delInf']['firstName'],

			"x_ship_to_last_name"   => $basket['delInf']['lastName'],

			"x_ship_to_address"	 => $basket['delInf']['add_1'], 

			"x_ship_to_city"		=> $basket['delInf']['town'],

			"x_ship_to_state"	   => $basket['delInf']['county'],

			"x_ship_to_zip"		 => $basket['delInf']['postcode'],

			"x_ship_to_country"	 => $basket['delInf']['country'],



			"x_email"				=> trim($_POST['emailAddress']),

			"x_customer_ip" 		=> get_ip_address()

		

		);




But the debugging report from Authorize.net looks like this:




04: Parse the results string into individual, meaningful segments:

Length of the returned string from Authorize.Net:	309

Number of delimiter characters in the returned string:	68

Response Code: 	Approved

Response Subcode: 	1

Response Reason Code: 	1

Response Reason Text: 	(TESTMODE) This transaction has been approved.

Approval Code: 	000000

AVS Result Code: 	P

Transaction ID: 	0

Invoice Number (x_invoice_num): 	071228-010956-6468

Description (x_description): 	Payment for order number 071228-010956-6468

Amount (x_amount): 	4.71

Method (x_method): 	CC

Transaction Type (x_type): 	auth_capture

Customer ID (x_cust_id): 	NO VALUE RETURNED

Cardholder First Name (x_first_name): 	Winifred

Cardholder Last Name (x_last_name): 	Hornswaggler

Company (x_company): 	NO VALUE RETURNED

Billing Address (x_address): 	1234 Main Street

City (x_city): 	Seattle

State (x_state): 	Washington

ZIP (x_zip): 	98104

Country (x_country): 	NO VALUE RETURNED

Phone (x_phone): 	NO VALUE RETURNED

Fax (x_fax): 	NO VALUE RETURNED

E-Mail Address (x_email): 	[email protected]

Ship to First Name (x_ship_to_first_name): 	NO VALUE RETURNED

Ship to Last Name (x_ship_to_last_name): 	NO VALUE RETURNED

Ship to Company (x_ship_to_company): 	NO VALUE RETURNED

Ship to Address (x_ship_to_address): 	NO VALUE RETURNED

Ship to City (x_ship_to_city): 	NO VALUE RETURNED

Ship to State (x_ship_to_state): 	NO VALUE RETURNED

Ship to ZIP (x_ship_to_zip): 	NO VALUE RETURNED

Ship to Country (x_ship_to_country): 	US

I'm using CC 4.1.0RC2

Does anyone have any ideas with this? Is there another page of code I should be looking at? Help!

Thanks,

m.

Link to comment
Share on other sites

  • 3 weeks later...

$basket array does not exist thus empty values. You should use appropriate value from $orderSum:

$orderSum['name_d']

$orderSum['companyName_d']

$orderSum['add_1_d']

$orderSum['add_2_d']

$orderSum['town_d']

$orderSum['county_d']

$orderSum['postcode_d']

$orderSum['country_d']

title, first and last name joined to $orderSum['name_d']

Link to comment
Share on other sites

  • 4 weeks later...

Have you managed to get the ship_to info to pass over to AN and populate in the emails using Authorize.net AIM with Version 4.1.1? I am having the same problem as you had/have, though no success with the suggestions offered here? Not sure exactly how to modify the form.inc.php to that end? Any help with this would be greatly appreciated!

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...