
Originally Posted by
regenbauma
Anyone have suggestions on how do we get the google cart to display products codes, and better still return product codes to zencart in the response message so that products are displayed in our order list.
My installation has the full google checkout process working except that
the order in the zencart list does not display product details .... all other aspects of the order are fine ...but the product purchased is not displayed ?
the received xml looks like
<product-data>;1</product-data> which is the product code
and
<items>^M
<item>^M
<quantity>1</quantity>^M
<unit-price currency="USD">0.2</unit-price>^M
<item-name>8&quot; Classic Frypan</item-name>^M
<item-description></item-description>^M
<tax-table-selector>Taxable Goods</tax-table-selector>^M
</item>^M
</items>^M
expect the order does not display the product ordered .... anyone have any clues in this regard ..... as I saw above ... perhaps the product code with the ";" is confusing things .... has anyone encountered this , and or repaired it ..
looks like may have something to do with
$tok = strtok($product_list, ";");
while($tok != FALSE) {
$product_id = $tok;
$new_cart->add_cart($product_id);
$tok = strtok(";");
in responsehandler.php .... but im no expert ... any help is appreciated
hi
try changing in catalog/googlecheckout/responsehandler.php line 153
PHP Code:
$new_cart = new shoppingCart;
$product_list = $data[$root]['shopping-cart']['merchant-private-data']['product-data'];
//Retrieve the list of product ids to get the contents of the cart when it was posted
$tok = strtok($product_list, ";");
while($tok != FALSE) {
$product_id = $tok;
$new_cart->add_cart($product_id);
$tok = strtok(";");
}
//$products = $new_cart->get_products();
//Reset the cart stored in the session
$_SESSION['cart']->reset(TRUE);
$orders_id = process_new_order_notification($root, $data, $googlepayment, $cart, $_SESSION['customer_id'], $_SESSION['languages_id'], $message_log); //$new_cart is empty. Changed to $cart - Added by colosports.
PHP Code:
// not used any more
/*
$new_cart = new shoppingCart;
$product_list = $data[$root]['shopping-cart']['merchant-private-data']['product-data']['VALUE'];
//Retrieve the list of product ids to get the contents of the cart when it was posted
$tok = strtok($product_list, ";");
while($tok != FALSE) {
$product_id = $tok;
$new_cart->add_cart($product_id);
$tok = strtok(";");
}
//$products = $new_cart->get_products();
*/
$orders_id = process_new_order_notification($root, $data, $googlepayment, $cart, $_SESSION['customer_id'], $_SESSION['languages_id'], $message_log); //$new_cart is empty. Changed to $cart - Added by colosports.
//Reset the cart stored in the session
$_SESSION['cart']->reset(TRUE);
Im working on a new release that will also support merchant calculations i think next week i'll have more news.
For those who want, i can check regularly our SVN, there are the latest code drops.
http://code.google.com/p/google-checkout-zencart/
thx for your feedbacks
ropu
Bookmarks