Hi Rebecca
I understood your problem now it seems i need to a setting to plugin to turn on and off the Line Item sending
For meantime can you comment out following to remove line items code entirely, please
foreach ( WC()->cart->get_cart() as $cart_item ) {
$item_name = substr( strip_tags($cart_item['data']->get_title() ) ,0,30) ;
$item_quantity = $cart_item['quantity'];
$item_price = $cart_item['data']->get_price();
$item_taxable = $cart_item['data']->is_taxable() == true ? 'Y':'N';
if($item_quantity > 0 && $item_price > 0 ){
$sale->addLineItem($i, $item_name, $item_name, $item_quantity, $item_price, $item_taxable);
}
$i++;
}
Greetings,
Has an update been made to the plugin regarding this issue? I just had a customer unable to process their order and receive the following message:
The number of line items submitted is not allowed. A maximum of 30 line items can be submitted.—AuthorizeNet Error:
Response Code: 3
Response Subcode: 1
Response Reason Code: 271
Response Reason Text: The number of line items submitted is not allowed. A maximum of 30 line items can be submitted.
on 16-Mar-2018 05:54:48 UTC using AUTH_CAPTURE
Thanks.
Hi cccnate,
Since there are more than 30 line items you will have comment out the lines above
Because authorize.net expects a maximum of 30 items
Thanks
We are having the same issue as well. Most of our orders contain more than 30 line items. Where exactly do we use the code you mentioned? We still need all of the line items to show up on the invoice.
Gasusant,
In our case, we edited the file:
…wp-content/plugins/authorizenet-woocommerce-addon/authorize.net-woocommerce-addon.php
Just find the code listed above, and comment it out (see below)
/*
foreach ( WC()->cart->get_cart() as $cart_item ) {
$item_name = substr( strip_tags($cart_item[‘data’]->get_title() ) ,0,30) ;
$item_quantity = $cart_item[‘quantity’];
$item_price = $cart_item[‘data’]->get_price();
$item_taxable = $cart_item[‘data’]->is_taxable() == true ? ‘Y’:’N’;
if($item_quantity > 0 && $item_price > 0 ){
$sale->addLineItem($i, $item_name, $item_name, $item_quantity, $item_price, $item_taxable); }
$i++; }
*/