Page 37 of 40 FirstFirst ... 273536373839 ... LastLast
Results 361 to 370 of 397
  1. #361
    Join Date
    Sep 2003
    Location
    Ohio
    Posts
    69,402
    Plugin Contributions
    6

    Default Re: Optional Shipping Insurance Module Support Thread...

    aldo.campione ... out of curiosity, what shipping module(s) are you using?
    Linda McGrath
    If you have to think ... you haven't been zenned ...

    Did YOU buy the Zen Cart Team a cup of coffee and a donut today? Just click here to support the Zen Cart Team!!

    Are you using the latest? Perhaps you've a problem that's fixed in the latest version: [Upgrade today: v1.5.5]
    Officially PayPal-Certified! Just click here

    Try our Zen Cart Recommended Services - Hosting, Payment and more ...
    Signup for our Announcements Forums to stay up to date on important changes and updates!

  2. #362
    Join Date
    Dec 2009
    Location
    Amersfoort, The Netherlands
    Posts
    2,846
    Plugin Contributions
    25

    Default Re: Optional Shipping Insurance Module Support Thread...

    It has been some years i last checked this module, but if i remember correctly the optional in this module is that you set the insurance to kick in above a certain total price in your cart.

  3. #363
    Join Date
    Apr 2015
    Location
    United States
    Posts
    15
    Plugin Contributions
    0

    Default Re: Optional Shipping Insurance Module Support Thread...

    Does anyone know how I might fix this so it will work with the
    edit_orders-4
    module.

    My insurance adds correctly in the regular order total during check-out, but whenever you edit the order using the Edit Orders 4 interface, the new order total always leaves out the Shipping Insurance amount.

    ???

    Andy

  4. #364
    Join Date
    Jun 2009
    Location
    Orange County, California
    Posts
    544
    Plugin Contributions
    18

    Default Re: Optional Shipping Insurance Module Support Thread...

    @Andy_M - Did you ever find a solution to this? I am having the same problem with Edit Orders 4.1.4

  5. #365
    Join Date
    Sep 2009
    Location
    Stuart, FL
    Posts
    12,478
    Plugin Contributions
    88

    Default Re: Optional Shipping Insurance Module Support Thread...

    Quote Originally Posted by Andy_M View Post
    Does anyone know how I might fix this so it will work with the
    edit_orders-4
    module.

    My insurance adds correctly in the regular order total during check-out, but whenever you edit the order using the Edit Orders 4 interface, the new order total always leaves out the Shipping Insurance amount.

    ???

    Andy
    Quote Originally Posted by jackie.taferner View Post
    @Andy_M - Did you ever find a solution to this? I am having the same problem with Edit Orders 4.1.4
    Assuming that you both are discussing the plugin that's downloaded from the Plugins' area, it's relying on checkout-based session information to determine whether it's to be enabled and will require modification to work with EO 4.1.4 (since the admin environment contains no such session information).

  6. #366
    Join Date
    Jun 2009
    Location
    Orange County, California
    Posts
    544
    Plugin Contributions
    18

    Default Re: Optional Shipping Insurance Module Support Thread...

    Thanks @lat9, yes I am trying to get this working on a client's site as we speak. Are there any plans to upgrade this module to not use session-based information on the backend? Or any pointers on how to accomplish this upgrade?

  7. #367
    Join Date
    Jun 2009
    Location
    Orange County, California
    Posts
    544
    Plugin Contributions
    18

    Default Re: Optional Shipping Insurance Module Support Thread...

    Ok, for anyone else looking to fix up this module for Edit Orders v4.1.4, here's a bit of a workaround, but it seems to get the job done.

    YOURADMIN/edit_orders.php

    Right around line 430:
    Code:
    			foreach($_POST['update_total'] as $order_total) {
    				$order_total['text'] = $currencies->format($order_total['value'], true, $order->info['currency'], $order->info['currency_value']);
    				$order_total['sort_order'] = $GLOBALS[$order_total['code']]->sort_order;
    
    				// TODO Special processing for some modules
    				if(zen_not_null($order_total['title']) && $order_total['title'] != ':') {
    					switch($order_total['code']) {
    						case 'ot_shipping':
    							$GLOBALS['order']->info['shipping_cost'] = $order_total['value'];
    							$GLOBALS['order']->info['shipping_module_code'] = $order_total['shipping_module'];
    							break;
    Add this code:
    Code:
    			//unset the insurance session before loading the next order
    			$_SESSION['opt_insurance'] = false;
    			foreach($_POST['update_total'] as $order_total) {
    				$order_total['text'] = $currencies->format($order_total['value'], true, $order->info['currency'], $order->info['currency_value']);
    				$order_total['sort_order'] = $GLOBALS[$order_total['code']]->sort_order;
    
    				// TODO Special processing for some modules
    				if(zen_not_null($order_total['title']) && $order_total['title'] != ':') {
    					switch($order_total['code']) {
    						//add insurance session if order has insurance
    						case 'ot_insurance':
    							$_SESSION['opt_insurance'] = true;
    							break;
    						case 'ot_shipping':
    							$GLOBALS['order']->info['shipping_cost'] = $order_total['value'];
    							$GLOBALS['order']->info['shipping_module_code'] = $order_total['shipping_module'];
    							break;

  8. #368
    Join Date
    Jul 2011
    Posts
    146
    Plugin Contributions
    4

    Default Re: Optional Shipping Insurance Module Support Thread...

    I have a question I've upgraded my Zen Cart installation from 1.5.5e to 1.5.5f in my development server, as well as upgrading from PHP 5.6 to PHP 7.1.
    I've made sure my customization php.ini definitions are migrated too.

    Going through QC testing I've noticed ot_insurance no longer functions properly.
    First symptom is upon a user attempts to checkout and pay for the product on index.php?main_page=checkout_payment , the screen returns blank.
    Second symptom is the edit Edit and Remove buttons within the administration page of the module does not show up anymore. The module list is of course still green light. I can click on the module listing again to edit the attribute of the module that way.

    According to the debug log, there's evident that something isnt compatible with the module.
    [18-Jan-2018 20:08:08 America/Los_Angeles] PHP Fatal error: Uncaught Error: Call to undefined function split() in /home/www/includes/modules/order_total/ot_insurance.php:128
    Stack trace:
    #0 /home/www/includes/classes/order_total.php(185): ot_insurance->process()
    #1 /home/www/includes/modules/pages/checkout_payment/header_php.php(101): order_total->pre_confirmation_check()
    #2 /home/www/index.php(36): require('/home/apusa/ang...')
    #3 {main}
    thrown in /home/www/includes/modules/order_total/ot_insurance.php on line 128


    Disabling, but not Removing (Since I cant do that without the button) the module will make my shopping cart work again.

    Also ZC 1.5.5e and 1.5.5f works with Php 5.6 but this issue appears within Php 7.1 So far, I have no other issues with other modules, and general functionality of the cart except this module. As I'd like to force my customers to have insurance for every order.
    Now, I think there's a work around using the USPS shipping insurance check box, and not using this module at all. But that is a bad work around as it does not show the customer that they are being charged for the extra service.

    Any help would be greatly appreciated!

  9. #369
    Join Date
    Sep 2009
    Location
    Stuart, FL
    Posts
    12,478
    Plugin Contributions
    88

    Default Re: Optional Shipping Insurance Module Support Thread...

    The PHP split function was deprecated (i.e. letting you know that it' going to be removed) in PHP 5.3.0 and removed totally in PHP 7.0. That's why the ot_insurance worked under PHP 5.6 but not under PHP 7.0.

    If you would post the contents of /includes/modules/order_total/ot_insurance.php's function on/around line 128, perhaps someone could propose a code-change to allow that order-total to (again) operate.

  10. #370
    Join Date
    Jul 2011
    Posts
    146
    Plugin Contributions
    4

    Default Re: Optional Shipping Insurance Module Support Thread...

    Quote Originally Posted by lat9 View Post
    The PHP split function was deprecated (i.e. letting you know that it' going to be removed) in PHP 5.3.0 and removed totally in PHP 7.0. That's why the ot_insurance worked under PHP 5.6 but not under PHP 7.0.

    If you would post the contents of /includes/modules/order_total/ot_insurance.php's function on/around line 128, perhaps someone could propose a code-change to allow that order-total to (again) operate.
    Okay that sounds logical enough.
    This is the latest version from both Numinix's website and the one uploaded in the ZC Plugins page. Version number is 3.2.2
    I look the liberty checking if there other occurrence of the split and I have found two. Here they are:

    Starts at Line 125
    // usps still open
    $table = constant('MODULE_ORDER_TOTAL_INSURANCE_COST_' . $this->dest_zone);
    $table_cost = split("[:,]", $table);
    $size = sizeof($table_cost);
    for ($i=0, $n=$size; $i<$n; $i+=2) {
    if (round($order_total_insurance,9) <= $table_cost[$i]) {
    $insurance = $table_cost[$i+1];
    break;
    Ends at Line 132

    Starts at Line 219
    if (MODULE_ORDER_TOTAL_INSURANCE_TABLE == 'true') {
    $table = constant('MODULE_ORDER_TOTAL_INSURANCE_COST_' . $this->dest_zone);
    $table_cost = split("[:,]", $table);
    $size = sizeof($table_cost);
    for ($i=0, $n=$size; $i<$n; $i+=2) {
    if (round($order_total_insurance,9) <= $table_cost[$i]) {
    $insurance = $table_cost[$i+1];
    break;
    }
    Ends at 227

 

 
Page 37 of 40 FirstFirst ... 273536373839 ... LastLast

Similar Threads

  1. Optional Shipping Insurance Module Question
    By kminnich in forum Built-in Shipping and Payment Modules
    Replies: 0
    Last Post: 7 Oct 2008, 01:16 AM
  2. Optional Shipping Insurance Module
    By Darkwander in forum Addon Shipping Modules
    Replies: 2
    Last Post: 9 Oct 2006, 02:18 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
disjunctive-egg
Zen-Cart, Internet Selling Services, Klamath Falls, OR