Jump to content

carlost

Members
  • Content count

    211
  • Joined

  • Last visited

1 Follower

About carlost

  • Birthday 01/01/2006

Profile Information

  • Real Name
    Carlos Thomas
  • Website
  1. carlost

    GOOGLE CHECKOUT IPN

    Hi Ski, I had already downloaded and implemented the EXTRAS optional modifications. My problem is not in viewing the numbers. My problem is, I am not getting anything added to the database to begin with, in neither table (google_checkout_logs & orders). Nor do I get any info in the google_log.txt file). I have only tested in the sandbox environment. I am a little confused about the google_log.txt file, as I thought to begin with it was meant for debugging, and therefore I assumed that there wouldn't be information inserted if there were no problems. However, I am under the impression now, from others experiences shared here that order information is inputted into google_log.txt as a regular part of the contributions process. So, I am just wondering if you might have any thoughts (assuming for the moment that my install is correct) as to why I wouldn't be getting the Google Order ID Number inserted into the google_checkout_logs & orders tables? Regards, CT
  2. carlost

    GOOGLE CHECKOUT IPN

    Hello, If anyone has an example of a .htaccess file that prevents access, but still allows the information to be written, it would be much appreciated. I have no clue as to what's needed here. Regards, CT
  3. carlost

    GOOGLE CHECKOUT IPN

    Hello Again, I don't know if this is what you're experiencing, but if two addresses are involved (customers oscommerce address is different than his or her Google address), and if the address used in oscommerce, is not in a tax zone, no matter if the address used for Google is, it won't show as taxable because the original address is what is processed. Maybe in time someone will come up with a way to prevent this from happening, or at least flag it in some manner. Regards again, CT
  4. carlost

    GOOGLE CHECKOUT IPN

    Hello, This contribution already supports The CCGV gift vouchers & Discount Coupons contribution. But you have to modify the google_checkout_process.php file to match the modifications made to your checkout_process.php file. As is, I don't think it supports any other discount coupon contribution. In my install, if using a Gift Certificate to pay for the entire order, you tick the "use available gift certificate amount" checkbox, and no matter if any other payment option is selected (including Google Checkout IPN), or if no payment option is selected - clicking through the rest of the checkout process brings you to checkout_success.php. Regards, CT
  5. carlost

    GOOGLE CHECKOUT IPN

    Hello, I'm in the states, I was just stating that the code did work for me. Sorry for the confusion. Regards, CT
  6. carlost

    GOOGLE CHECKOUT IPN

    Hello, I'm wondering about other experiences around two things. I cannot get the Google order number, via the call back in a testing environment. I get no errors as far as I can tell; I just don't get the Google order number updated to the data base in either the google_checkout_logs table or the orders table. So, I don't get status updates either. I've tried the suggested (adding (int)), still nothing. I am hoping that this is maybe specific to my testing environment. However, I have the same situation with several different testing environments. The second thing is: I just became aware that options/attributes are not being shown in the Google cart. They are being passed through to the order via google_checkout_process.php so it's not an imperative problem, but I'm thinking it's a little less than what a customer might expect to see. If anyone has addressed this already, I'd be interested to know about it. Regards, CT
  7. carlost

    GOOGLE CHECKOUT IPN

    Hello Ski! Welcome, and thank you for all that you do! The contribution works quite a bit better already due to your involvement - again, thank you for all that you do! Just to let you know, this works well for me - again, again, thank you for all that you do! Regards, CT
  8. carlost

    GOOGLE CHECKOUT IPN

    The above code modification is incorrect (concerning the "admin/categories.php" file, and "7) Replace with:"). It should be: </tr> <!-- prevent GCIPN payment option --> <tr bgcolor="#ebebff"> <td class="main"><?php echo TEXT_PRODUCTS_GOOGLE_PAYMENT_PRODUCT; ?></td> <td class="main"><?php echo tep_draw_separator('pixel_trans.gif', '24', '15') . ' ' . tep_draw_pull_down_menu('products_google_payment_product', $google_payment_product_array, $pInfo->products_google_payment_product); ?></td> </tr> <!-- /prevent GCIPN payment option -->
  9. carlost

    GOOGLE CHECKOUT IPN

    Hello, The following modifications will allow you to select whether or not a product can be purchased through the Google Checkout IPN, on a per product basis. It is by default set for each product to be able to. To set a product to not be able to be purchased using the Google Checkout IPN payment option - in the admin ui's product page (categories.php) you just set the newly created "Allow Google Payment:" drop down to "No". Though it is presented here based on a vanilla 2.2 install, it's not been tested on a vanilla install. It was originally done for a heavily modified install. It's been put together by mimicking code from oscommerce and several oscommerce contributions, and it is not likely coded efficiently, nor prudently. I don't even know that all the code is necessary. I do know it works well in my modified environment. As an aside, I've used the same/similar procedure/process to make several different per product switches/flags and triggers. Regards, CT In: admin/categories.php 1) Find: 'manufacturers_id' => tep_db_prepare_input($HTTP_POST_VARS['manufacturers_id'])); 1) Replace with: 'manufacturers_id' => tep_db_prepare_input($HTTP_POST_VARS['manufacturers_id']), // prevent GCIPN payment option 'products_google_payment_product' => tep_db_prepare_input($HTTP_POST_VARS['products_google_payment_product'])); // /prevent GCIPN payment option 2) Find: $product_query = tep_db_query("select products_quantity, products_model, products_image, products_price, products_date_available, products_weight, products_tax_class_id, manufacturers_id from " . TABLE_PRODUCTS . " where products_id = '" . (int)$products_id . "'"); 2) Replace with: // prevent GCIPN payment option (added: , products_google_payment_product) $product_query = tep_db_query("select products_quantity, products_model, products_image, products_price, products_date_available, products_weight, products_tax_class_id, manufacturers_id, products_google_payment_product from " . TABLE_PRODUCTS . " where products_id = '" . (int)$products_id . "'"); // /prevent GCIPN payment option (added: , products_google_payment_product) 3) Find: tep_db_query("insert into " . TABLE_PRODUCTS . " (products_quantity, products_model,products_image, products_price, products_date_added, products_date_available, products_weight, products_status, products_tax_class_id, manufacturers_id) values ('" . tep_db_input($product['products_quantity']) . "', '" . tep_db_input($product['products_model']) . "', '" . tep_db_input($product['products_image']) . "', '" . tep_db_input($product['products_price']) . "', now(), " . (empty($product['products_date_available']) ? "null" : "'" . tep_db_input($product['products_date_available']) . "'") . ", '" . tep_db_input($product['products_weight']) . "', '0', '" . (int)$product['products_tax_class_id'] . "', '" . (int)$product['manufacturers_id'] . "')"); 3) Replace with: // prevent GCIPN payment option (added: , products_google_payment_product) tep_db_query("insert into " . TABLE_PRODUCTS . " (products_quantity, products_model,products_image, products_price, products_date_added, products_date_available, products_weight, products_status, products_tax_class_id, manufacturers_id, products_google_payment_product) values ('" . tep_db_input($product['products_quantity']) . "', '" . tep_db_input($product['products_model']) . "', '" . tep_db_input($product['products_image']) . "', '" . tep_db_input($product['products_price']) . "', now(), " . (empty($product['products_date_available']) ? "null" : "'" . tep_db_input($product['products_date_available']) . "'") . ", '" . tep_db_input($product['products_weight']) . "', '0', '" . (int)$product['products_tax_class_id'] . "', '" . (int)$product['manufacturers_id'] . "')"); // /prevent GCIPN payment option (added: , products_google_payment_product) 4) Find: 'manufacturers_id' => ''); 4) Replace with: 'manufacturers_id' => '', // prevent GCIPN payment option 'products_google_payment_product' => ''); // /prevent GCIPN payment option 5) Find: $product_query = tep_db_query("select pd.products_name, pd.products_description, pd.products_url, p.products_id, p.products_quantity, p.products_model, p.products_image, p.products_price, p.products_weight, p.products_date_added, p.products_last_modified, date_format(p.products_date_available, '%Y-%m-%d') as products_date_available, p.products_status, p.products_tax_class_id, p.manufacturers_id from " . TABLE_PRODUCTS . " p, " . TABLE_PRODUCTS_DESCRIPTION . " pd where p.products_id = '" . (int)$HTTP_GET_VARS['pID'] . "' and p.products_id = pd.products_id and pd.language_id = '" . (int)$languages_id . "'"); 5) Replace with: // prevent GCIPN payment option (added: , p.products_google_payment_product) $product_query = tep_db_query("select pd.products_name, pd.products_description, pd.products_url, p.products_id, p.products_quantity, p.products_model, p.products_image, p.products_price, p.products_weight, p.products_date_added, p.products_last_modified, date_format(p.products_date_available, '%Y-%m-%d') as products_date_available, p.products_status, p.products_tax_class_id, p.manufacturers_id, p.products_google_payment_product from " . TABLE_PRODUCTS . " p, " . TABLE_PRODUCTS_DESCRIPTION . " pd where p.products_id = '" . (int)$HTTP_GET_VARS['pID'] . "' and p.products_id = pd.products_id and pd.language_id = '" . (int)$languages_id . "'"); // /prevent GCIPN payment option (added: , p.products_google_payment_product) 6) Find: $tax_class_array = array(array('id' => '0', 'text' => TEXT_NONE)); 6) Replace with: // prevent GCIPN payment option $google_payment_product_array = array(array('id' => '1', 'text' => TEXT_YES), array('id' => '0', 'text' => TEXT_NO)); // /prevent GCIPN payment option $tax_class_array = array(array('id' => '0', 'text' => TEXT_NONE)); First Find: TEXT_PRODUCTS_PRICE_GROSS 7) Then find 2 lines below: </tr> 7) Replace with: </tr> // prevent GCIPN payment option <tr bgcolor="#ebebff"> <td class="main"><?php echo TEXT_PRODUCTS_GOOGLE_PAYMENT_PRODUCT; ?></td> <td class="main"><?php echo tep_draw_separator('pixel_trans.gif', '24', '15') . ' ' . tep_draw_pull_down_menu('products_google_payment_product', $google_payment_product_array, $pInfo->products_google_payment_product); ?></td> </tr> // /prevent GCIPN payment option 8) Find: $product_query = tep_db_query("select p.products_id, pd.language_id, pd.products_name, pd.products_description, pd.products_url, p.products_quantity, p.products_model, p.products_image, p.products_price, p.products_weight, p.products_date_added, p.products_last_modified, p.products_date_available, p.products_status, p.manufacturers_id from " . TABLE_PRODUCTS . " p, " . TABLE_PRODUCTS_DESCRIPTION . " pd where p.products_id = pd.products_id and p.products_id = '" . (int)$HTTP_GET_VARS['pID'] . "'"); 8) Replace with: // prevent GCIPN payment option (added: , p.products_google_payment_product) $product_query = tep_db_query("select p.products_id, pd.language_id, pd.products_name, pd.products_description, pd.products_url, p.products_quantity, p.products_model, p.products_image, p.products_price, p.products_weight, p.products_date_added, p.products_last_modified, p.products_date_available, p.products_status, p.manufacturers_id, p.products_google_payment_product from " . TABLE_PRODUCTS . " p, " . TABLE_PRODUCTS_DESCRIPTION . " pd where p.products_id = pd.products_id and p.products_id = '" . (int)$HTTP_GET_VARS['pID'] . "'"); // /prevent GCIPN payment option (added: , p.products_google_payment_product) 9) Find: $products_query = tep_db_query("select p.products_id, pd.products_name, p.products_quantity, p.products_image, p.products_price, p.products_date_added, p.products_last_modified, p.products_date_available, p.products_status, p2c.categories_id from " . TABLE_PRODUCTS . " p, " . TABLE_PRODUCTS_DESCRIPTION . " pd, " . TABLE_PRODUCTS_TO_CATEGORIES . " p2c where p.products_id = pd.products_id and pd.language_id = '" . (int)$languages_id . "' and p.products_id = p2c.products_id and pd.products_name like '%" . tep_db_input($search) . "%' order by pd.products_name"); 9) Replace with: // prevent GCIPN payment option (added: , p.products_google_payment_product) $products_query = tep_db_query("select p.products_id, pd.products_name, p.products_quantity, p.products_image, p.products_price, p.products_date_added, p.products_last_modified, p.products_date_available, p.products_status, p2c.categories_id, p.products_google_payment_product from " . TABLE_PRODUCTS . " p, " . TABLE_PRODUCTS_DESCRIPTION . " pd, " . TABLE_PRODUCTS_TO_CATEGORIES . " p2c where p.products_id = pd.products_id and pd.language_id = '" . (int)$languages_id . "' and p.products_id = p2c.products_id and pd.products_name like '%" . tep_db_input($search) . "%' order by pd.products_name"); // /prevent GCIPN payment option (added: , p.products_google_payment_product) 10) Find: $products_query = tep_db_query("select p.products_id, pd.products_name, p.products_quantity, p.products_image, p.products_price, p.products_date_added, p.products_last_modified, p.products_date_available, p.products_status from " . TABLE_PRODUCTS . " p, " . TABLE_PRODUCTS_DESCRIPTION . " pd, " . TABLE_PRODUCTS_TO_CATEGORIES . " p2c where p.products_id = pd.products_id and pd.language_id = '" . (int)$languages_id . "' and p.products_id = p2c.products_id and p2c.categories_id = '" . (int)$current_category_id . "' order by pd.products_name"); 10) Replace with: // prevent GCIPN payment option (added: , p.products_google_payment_product) $products_query = tep_db_query("select p.products_id, pd.products_name, p.products_quantity, p.products_image, p.products_price, p.products_date_added, p.products_last_modified, p.products_date_available, p.products_status, p.products_google_payment_product from " . TABLE_PRODUCTS . " p, " . TABLE_PRODUCTS_DESCRIPTION . " pd, " . TABLE_PRODUCTS_TO_CATEGORIES . " p2c where p.products_id = pd.products_id and pd.language_id = '" . (int)$languages_id . "' and p.products_id = p2c.products_id and p2c.categories_id = '" . (int)$current_category_id . "' order by pd.products_name"); // /prevent GCIPN payment option (added: , p.products_google_payment_product) 11) Find: $contents[] = array('text' => '<br>' . TEXT_PRODUCTS_AVERAGE_RATING . ' ' . number_format($pInfo->average_rating, 2) . '%'); 11) Replace with: $contents[] = array('text' => '<br>' . TEXT_PRODUCTS_AVERAGE_RATING . ' ' . number_format($pInfo->average_rating, 2) . '%'); // prevent GCIPN payment option if ($pInfo->products_google_payment_product == "1") { $google_payment_product_indicator = TEXT_YES; } else { $google_payment_product_indicator = TEXT_NO; } $contents[] = array('text' => '' . TEXT_PRODUCTS_GOOGLE_PAYMENT_PRODUCT . ' ' . $google_payment_product_indicator . ''); // /prevent GCIPN payment option ---------------------------- In: admin/includes/languages/english/categories.php 1) Find: ?> 1) Replace with: // prevent GCIPN payment option define('TEXT_PRODUCTS_GOOGLE_PAYMENT_PRODUCT', 'Allow Google Payment:'); // /prevent GCIPN payment option ?> ---------------------------- In: checkout_payment.php 2) Find: $selection = $payment_modules->selection(); 2) Replace with: $selection = $payment_modules->selection(); // prevent GCIPN payment option $order->info['g_payment'] = $cart->g_payment; if (($cart->g_payment) > 0) { for($i=0, $n=sizeof($selection); $i<$n; $i++) { if($selection[$i]['module'] == MODULE_PAYMENT_GOOGLE_TEXT_TITLE) { array_splice($selection, $i, 1); break; } } } // /prevent GCIPN payment option ---------------------------- In: includes/classes/shopping_cart.php 1) Find: var $contents, $total, $weight, $cartID, $content_type; 1) Replace with: // prevent GCIPN payment option (added: , $g_payment) var $contents, $total, $weight, $cartID, $content_type, $g_payment; // /prevent GCIPN payment option (added: , $g_payment) First Find: function calculate() { 2) Then find 2 lines below: $this->weight = 0; 2) Replace with: $this->weight = 0; // prevent GCIPN payment option $this->g_payment = 0; // /prevent GCIPN payment option 3) Find: $product_query = tep_db_query("select products_id, products_price, products_tax_class_id, products_weight from " . TABLE_PRODUCTS . " where products_id = '" . (int)$products_id . "'"); 3) Replace with: // prevent GCIPN payment option (added: , products_google_payment_product) $product_query = tep_db_query("select products_id, products_price, products_tax_class_id, products_weight, products_google_payment_product from " . TABLE_PRODUCTS . " where products_id = '" . (int)$products_id . "'"); // /prevent GCIPN payment option (added: , products_google_payment_product) 4) Find: if ($product = tep_db_fetch_array($product_query)) { 4) Replace with: // prevent GCIPN payment option $products_google_payment_product = $product['products_google_payment_product']; // /prevent GCIPN payment option if ($product = tep_db_fetch_array($product_query)) { 5) Find: $this->total += tep_add_tax($products_price, $products_tax) * $qty; 5) Replace with: $this->total += tep_add_tax($products_price, $products_tax) * $qty; // prevent GCIPN payment option $this->g_payment += ($products_google_payment_product == 1)?0:(tep_add_tax($products_price, $products_tax) * $qty); // /prevent GCIPN payment option 6) Find: $this->total += $qty * tep_add_tax($attribute_price['options_values_price'], $products_tax); 6) Replace with: $this->total += $qty * tep_add_tax($attribute_price['options_values_price'], $products_tax); // prevent GCIPN payment option $this->g_payment += ($products_google_payment_product == 1)?0:($qty * tep_add_tax($attribute_price['options_values_price'], $products_tax)); // /prevent GCIPN payment option 7) Find: $this->total -= $qty * tep_add_tax($attribute_price['options_values_price'], $products_tax); 7) Replace with: $this->total -= $qty * tep_add_tax($attribute_price['options_values_price'], $products_tax); // prevent GCIPN payment option $this->g_payment -= ($products_google_payment_product == 1)?0:($qty * tep_add_tax($attribute_price['options_values_price'], $products_tax)); // /prevent GCIPN payment option ---------------------------- added sql: ALTER TABLE `products` ADD `products_google_payment_product` TINYINT( 1 ) DEFAULT '1' NOT NULL; END
  10. carlost

    GOOGLE CHECKOUT IPN

    Hello Ski, I just want to say well done! And, thanks for your time and efforts here! Regards, CT
  11. carlost

    GOOGLE CHECKOUT IPN

    Hello, The contribution already has code for CCGV gift vouchers & Discount Coupons written into it in the includes/modules/payment/google.php file. I am now assuming the discount coupons you are referring to is a separate, different contribution. I wouldn't know how to add the code for it. Maybe someone else would. Regards, CT
  12. carlost

    GOOGLE CHECKOUT IPN

    Hello, I believe the contribution is actually setup to use the ICW CREDIT CLASS Gift Voucher System. As well, I use it, and it works fine with the exception that's noted in the readme.txt. If you have any standard payment module setup (example: check/money order), and it works, you can likely rule out the checkout_confirmation.php file as being a problem. Regards, CT
  13. carlost

    GOOGLE CHECKOUT IPN

  14. carlost

    GOOGLE CHECKOUT IPN

    Hello, Not sure what you're saying here. If it is that you are getting back information based on your live Google Merchant ID & Merchant Key numbers, which are separate, and different from your Sandbox Merchant ID & Merchant Key numbers - where do you have your live Google Merchant ID & Merchant Key numbers inserted? Regards, CT
  15. carlost

    GOOGLE CHECKOUT IPN

    Hello, Just fishing some. Maybe try: chmod gclog/ to 777 & log.txt 666. If you would then like to post your checkout_process.php file here, might be able to determine something from it. Regards, CT
×