Page 233 of 282 FirstFirst ... 133183223231232233234235243 ... LastLast
Results 2,321 to 2,330 of 2812
  1. #2321
    Join Date
    Sep 2009
    Location
    Stuart, FL
    Posts
    12,498
    Plugin Contributions
    88

    Default Re: One-Page Checkout [Support Thread]

    Quote Originally Posted by Nick1973 View Post
    hi cindy,

    I have just installed OPC 2.4.1 on 1.5.7d running PHP 7.4 and I am getting this after card details have been entered and when clicking 'confirm order'

    Your order's details have changed. Please review the current values and re-submit.

    So I entered my card details again, and when I reconfirm the order, it goes through without a problem.
    What payment method? It sounds like something's not being recorded in the session on the initial 'confirm' click.

  2. #2322
    Join Date
    Sep 2008
    Location
    Cleethorpes
    Posts
    1,227
    Plugin Contributions
    6

    Default Re: One-Page Checkout [Support Thread]

    Quote Originally Posted by lat9 View Post
    What payment method? It sounds like something's not being recorded in the session on the initial 'confirm' click.
    Paypal and Square
    Nick Smith - Venture Design and Print
    https://venturedesignandprint.co.uk

  3. #2323
    Join Date
    Jan 2004
    Location
    N of San Antonio TX
    Posts
    9,154
    Plugin Contributions
    11

    Default Re: One-Page Checkout [Support Thread]

    Getting the same with WebPay but only occasionally.

    Also getting completed orders that trigger a PHP notice for a missing token. Followed the process with the console and saw no problem but the notice still appeared.

  4. #2324
    Join Date
    Sep 2009
    Location
    Stuart, FL
    Posts
    12,498
    Plugin Contributions
    88

    Default Re: One-Page Checkout [Support Thread]

    Quote Originally Posted by Nick1973 View Post
    Paypal and Square
    Quote Originally Posted by dbltoe View Post
    Getting the same with WebPay but only occasionally.

    Also getting completed orders that trigger a PHP notice for a missing token. Followed the process with the console and saw no problem but the notice still appeared.
    Enable the OPC debug and send the files to my direct email so that I can see what's going on.

  5. #2325
    Join Date
    Apr 2008
    Posts
    446
    Plugin Contributions
    1

    Default Re: One-Page Checkout [Support Thread]

    Hi Cindy,

    I'm running into an issue, non related to OPC but that is affecting it. The way ZC works when it comes to free shipping (free options) and gift vouchers is a bit odd. Ideally if I offer free shipping over $100 and the customer applies a $10 discount coupon for example, free shipping should not apply anymore. However the reality is, with the way ZC is designed free shipping still applies because freeoptions works on order subtotal not order total.

    The way I've made it work in the past was by hiding the place order button if certain conditions do not apply. I wrote a rudimentary piece code (perfected by @mc12345678 a little while back, to whom I will forever be grateful to) but I can't make it work with OPC.

    The code determines if both discount coupons and free shipping are loaded and if the order total drops below the free shipping threshold, then the button is hidden, for the most part. I placed the code in the tpl_checkout_confirmation_default.php on the native ZC checkout which is where the place order button displays. On OPC that could be according to what I've noticed the module works, on the tpl_modules_opc_submit_block.php, but it just doesn't work, and I was wondering if you could take a look and maybe point me in the right direction?

    This below is what I have.

    PHP Code:
    <?php
    // -----
    // Part of the One-Page Checkout plugin, provided under GPL 2.0 license by lat9 ().
    // Copyright (C) 2013-2017, Vinos de Frutas Tropicales.  All rights reserved.
    //
    // Check to see that at least one shipping-method and one payment-method is enabled; if not, don't render the submit-button.
    //
    if ($shipping_module_available && $payment_module_available) {
        
    // -----
        // Set up two form-submittal buttons, one for payment methods that require confirmation and one for those that don't.
        // This page's header_php.php has created an array of payment modules that require confirmation, which is pulled into the
        // page's jscript_main.php.
        //
    ?>
    <!-- bof disable checkout button from displaying 1 of 3 -->
     <?php
    if (!IS_ADMIN_FLAG) { 
        global 
    $order$db;
          if ((
    $order->info['total'] < MODULE_SHIPPING_FREEOPTIONS_TOTAL_MIN) && (substr_count($_SESSION['shipping']['id'], 'freeoptions') !=0) && !empty($_SESSION['cot_gv']) && (($_SESSION['cot_gv'] + $order->info['total']) >= MODULE_SHIPPING_FREEOPTIONS_TOTAL_MIN)) { // Do the following (show button) if total is below the min, free options is offered, a gift certificate is used and the sum of the gift certificate and order total is equal to or greater than the minimum.

         
    ?>
    <!-- bof disable checkout button from displaying 1 of 3 -->

    <!--bof submit block -->
      <div id="checkoutOneSubmit" class="buttonRow forward">
        <span id="opc-order-confirm"><?php echo zen_image_button(BUTTON_IMAGE_CHECKOUT_ONE_CONFIRMBUTTON_CHECKOUT_ONE_CONFIRM_ALT); ?></span>
        <span id="opc-order-review"><?php echo zen_image_button(BUTTON_IMAGE_CHECKOUT_ONE_REVIEWBUTTON_CHECKOUT_ONE_REVIEW_ALT); ?></span>
        <?php echo zen_draw_hidden_field('order_confirmed''1''id="confirm-the-order"') . zen_draw_hidden_field ('current_order_total''0''id="current-order-total"'); ?>
      </div>
    <?php
        
    if (!empty($order->customer['email_address'])) {
    ?>
      <div id="checkoutOneEmail" class="forward clearRight"><?php echo sprintf(TEXT_CONFIRMATION_EMAILS_SENT_TO$order->customer['email_address']); ?></div>
    <?php
        
    }
    ?>
      <div class="clearBoth"></div>
    <!--eof submit block -->

    <!-- bof disable checkout button from displaying 2 of 3 -->
     <?php } elseif (($order->info['total'] < MODULE_SHIPPING_FREEOPTIONS_TOTAL_MIN) && (substr_count($_SESSION['shipping']['id'], 'freeoptions') !=0)) { // Stop checkout if below the minimum and free options is displayed (Note that at this point of execution, the gift certificate is not a factor because if it "helped" then this code is not reached).
        
    echo '<div style="border: 3px solid #777777; padding: 10px 0;"><p style="text-align: center;"><strong>Your order no longer qualifies for Free Shipping.</strong></p>';  
        
      } else { 
    // standard checkout, basically total is anything that doesn't cause freeoptions to display.
    ?> 
    <!-- eof disable checkout button from displaying 2 of 2 -->

    <!--bof submit block -->
      <div id="checkoutOneSubmit" class="buttonRow forward">
        <span id="opc-order-confirm"><?php echo zen_image_button(BUTTON_IMAGE_CHECKOUT_ONE_CONFIRMBUTTON_CHECKOUT_ONE_CONFIRM_ALT); ?></span>
        <span id="opc-order-review"><?php echo zen_image_button(BUTTON_IMAGE_CHECKOUT_ONE_REVIEWBUTTON_CHECKOUT_ONE_REVIEW_ALT); ?></span>
        <?php echo zen_draw_hidden_field('order_confirmed''1''id="confirm-the-order"') . zen_draw_hidden_field ('current_order_total''0''id="current-order-total"'); ?>
      </div>
    <?php
        
    if (!empty($order->customer['email_address'])) {
    ?>
      <div id="checkoutOneEmail" class="forward clearRight"><?php echo sprintf(TEXT_CONFIRMATION_EMAILS_SENT_TO$order->customer['email_address']); ?></div>
    <?php
        
    }
    ?>
      <div class="clearBoth"></div>
    <!--eof submit block -->

    //<!-- bof disable checkout button from displaying 3 of 3 -->
    <?php
    }
    }
    When loading the page I get a popup "Please contact the store owner; some required elements of this page are missing" and in the logs "PHP Parse error: syntax error, unexpected end of file in /includes/templates/responsive_classic/templates/tpl_modules_opc_submit_block.php on line 68."

    Thanks in advance for your guidance.

  6. #2326
    Join Date
    Nov 2005
    Location
    los angeles
    Posts
    2,693
    Plugin Contributions
    9

    Default Re: One-Page Checkout [Support Thread]

    Quote Originally Posted by mvstudio View Post
    Hi Cindy,

    I'm running into an issue, non related to OPC but that is affecting it. The way ZC works when it comes to free shipping (free options) and gift vouchers is a bit odd. Ideally if I offer free shipping over $100 and the customer applies a $10 discount coupon for example, free shipping should not apply anymore. However the reality is, with the way ZC is designed free shipping still applies because freeoptions works on order subtotal not order total.

    The way I've made it work in the past was by hiding the place order button if certain conditions do not apply. I wrote a rudimentary piece code (perfected by @mc12345678 a little while back, to whom I will forever be grateful to) but I can't make it work with OPC.

    The code determines if both discount coupons and free shipping are loaded and if the order total drops below the free shipping threshold, then the button is hidden, for the most part. I placed the code in the tpl_checkout_confirmation_default.php on the native ZC checkout which is where the place order button displays. On OPC that could be according to what I've noticed the module works, on the tpl_modules_opc_submit_block.php, but it just doesn't work, and I was wondering if you could take a look and maybe point me in the right direction?

    This below is what I have.

    PHP Code:
    <?php
    // -----
    // Part of the One-Page Checkout plugin, provided under GPL 2.0 license by lat9 ().
    // Copyright (C) 2013-2017, Vinos de Frutas Tropicales.  All rights reserved.
    //
    // Check to see that at least one shipping-method and one payment-method is enabled; if not, don't render the submit-button.
    //
    if ($shipping_module_available && $payment_module_available) {
        
    // -----
        // Set up two form-submittal buttons, one for payment methods that require confirmation and one for those that don't.
        // This page's header_php.php has created an array of payment modules that require confirmation, which is pulled into the
        // page's jscript_main.php.
        //
    ?>
    <!-- bof disable checkout button from displaying 1 of 3 -->
     <?php
    if (!IS_ADMIN_FLAG) { 
        global 
    $order$db;
          if ((
    $order->info['total'] < MODULE_SHIPPING_FREEOPTIONS_TOTAL_MIN) && (substr_count($_SESSION['shipping']['id'], 'freeoptions') !=0) && !empty($_SESSION['cot_gv']) && (($_SESSION['cot_gv'] + $order->info['total']) >= MODULE_SHIPPING_FREEOPTIONS_TOTAL_MIN)) { // Do the following (show button) if total is below the min, free options is offered, a gift certificate is used and the sum of the gift certificate and order total is equal to or greater than the minimum.

         
    ?>
    <!-- bof disable checkout button from displaying 1 of 3 -->

    <!--bof submit block -->
      <div id="checkoutOneSubmit" class="buttonRow forward">
        <span id="opc-order-confirm"><?php echo zen_image_button(BUTTON_IMAGE_CHECKOUT_ONE_CONFIRMBUTTON_CHECKOUT_ONE_CONFIRM_ALT); ?></span>
        <span id="opc-order-review"><?php echo zen_image_button(BUTTON_IMAGE_CHECKOUT_ONE_REVIEWBUTTON_CHECKOUT_ONE_REVIEW_ALT); ?></span>
        <?php echo zen_draw_hidden_field('order_confirmed''1''id="confirm-the-order"') . zen_draw_hidden_field ('current_order_total''0''id="current-order-total"'); ?>
      </div>
    <?php
        
    if (!empty($order->customer['email_address'])) {
    ?>
      <div id="checkoutOneEmail" class="forward clearRight"><?php echo sprintf(TEXT_CONFIRMATION_EMAILS_SENT_TO$order->customer['email_address']); ?></div>
    <?php
        
    }
    ?>
      <div class="clearBoth"></div>
    <!--eof submit block -->

    <!-- bof disable checkout button from displaying 2 of 3 -->
     <?php } elseif (($order->info['total'] < MODULE_SHIPPING_FREEOPTIONS_TOTAL_MIN) && (substr_count($_SESSION['shipping']['id'], 'freeoptions') !=0)) { // Stop checkout if below the minimum and free options is displayed (Note that at this point of execution, the gift certificate is not a factor because if it "helped" then this code is not reached).
        
    echo '<div style="border: 3px solid #777777; padding: 10px 0;"><p style="text-align: center;"><strong>Your order no longer qualifies for Free Shipping.</strong></p>';  
        
      } else { 
    // standard checkout, basically total is anything that doesn't cause freeoptions to display.
    ?> 
    <!-- eof disable checkout button from displaying 2 of 2 -->

    <!--bof submit block -->
      <div id="checkoutOneSubmit" class="buttonRow forward">
        <span id="opc-order-confirm"><?php echo zen_image_button(BUTTON_IMAGE_CHECKOUT_ONE_CONFIRMBUTTON_CHECKOUT_ONE_CONFIRM_ALT); ?></span>
        <span id="opc-order-review"><?php echo zen_image_button(BUTTON_IMAGE_CHECKOUT_ONE_REVIEWBUTTON_CHECKOUT_ONE_REVIEW_ALT); ?></span>
        <?php echo zen_draw_hidden_field('order_confirmed''1''id="confirm-the-order"') . zen_draw_hidden_field ('current_order_total''0''id="current-order-total"'); ?>
      </div>
    <?php
        
    if (!empty($order->customer['email_address'])) {
    ?>
      <div id="checkoutOneEmail" class="forward clearRight"><?php echo sprintf(TEXT_CONFIRMATION_EMAILS_SENT_TO$order->customer['email_address']); ?></div>
    <?php
        
    }
    ?>
      <div class="clearBoth"></div>
    <!--eof submit block -->

    //<!-- bof disable checkout button from displaying 3 of 3 -->
    <?php
    }
    }
    When loading the page I get a popup "Please contact the store owner; some required elements of this page are missing" and in the logs "PHP Parse error: syntax error, unexpected end of file in /includes/templates/responsive_classic/templates/tpl_modules_opc_submit_block.php on line 68."

    Thanks in advance for your guidance.
    you are missing a closing curly brace at the end of the file.

    there should be 3. you only have 2.

    best.
    author of square Webpay.
    mxWorks has premium plugins. donations: venmo or paypal accepted.
    premium consistent excellent support. available for hire.

  7. #2327
    Join Date
    Apr 2008
    Posts
    446
    Plugin Contributions
    1

    Default Re: One-Page Checkout [Support Thread]

    Quote Originally Posted by carlwhat View Post
    you are missing a closing curly brace at the end of the file.

    there should be 3. you only have 2.

    best.
    How did I miss that one?! Thank you @carlwhat! I appreciate the extra pair of eyes!

  8. #2328
    Join Date
    Apr 2008
    Posts
    446
    Plugin Contributions
    1

    Default Re: One-Page Checkout [Support Thread]

    After adding the missing curly bracket the code doesn't work. Lowering the order total doesn't trigger the message nor hides the button. What am I doing wrong?

    PHP Code:
     <?php
    // -----
    // Part of the One-Page Checkout plugin, provided under GPL 2.0 license by lat9 ().
    // Copyright (C) 2013-2017, Vinos de Frutas Tropicales.  All rights reserved.
    //
    // Check to see that at least one shipping-method and one payment-method is enabled; if not, don't render the submit-button.
    //
    if ($shipping_module_available && $payment_module_available) {
        
    // -----
        // Set up two form-submittal buttons, one for payment methods that require confirmation and one for those that don't.
        // This page's header_php.php has created an array of payment modules that require confirmation, which is pulled into the
        // page's jscript_main.php.
        //
    ?>
    <!-- bof disable checkout button from displaying 1 of 3 -->
     <?php
    if (!IS_ADMIN_FLAG) { 
        global 
    $order$db;
          if ((
    $order->info['total'] < MODULE_SHIPPING_FREEOPTIONS_TOTAL_MIN) && (substr_count($_SESSION['shipping']['id'], 'freeoptions') !=0) && !empty($_SESSION['cot_gv']) && (($_SESSION['cot_gv'] + $order->info['total']) >= MODULE_SHIPPING_FREEOPTIONS_TOTAL_MIN)) { // Do the following (show button) if total is below the min, free options is offered, a gift certificate is used and the sum of the gift certificate and order total is equal to or greater than the minimum.

         
    ?>
    <!-- bof disable checkout button from displaying 1 of 3 -->

    <!--bof submit block -->
      <div id="checkoutOneSubmit" class="buttonRow forward">
        <span id="opc-order-confirm"><?php echo zen_image_button(BUTTON_IMAGE_CHECKOUT_ONE_CONFIRMBUTTON_CHECKOUT_ONE_CONFIRM_ALT); ?></span>
        <span id="opc-order-review"><?php echo zen_image_button(BUTTON_IMAGE_CHECKOUT_ONE_REVIEWBUTTON_CHECKOUT_ONE_REVIEW_ALT); ?></span>
        <?php echo zen_draw_hidden_field('order_confirmed''1''id="confirm-the-order"') . zen_draw_hidden_field ('current_order_total''0''id="current-order-total"'); ?>
      </div>
    <?php
        
    if (!empty($order->customer['email_address'])) {
    ?>
      <div id="checkoutOneEmail" class="forward clearRight"><?php echo sprintf(TEXT_CONFIRMATION_EMAILS_SENT_TO$order->customer['email_address']); ?></div>
    <?php
        
    }
    ?>
      <div class="clearBoth"></div>
    <!--eof submit block -->

    <!-- bof disable checkout button from displaying 2 of 3 -->
     <?php } elseif (($order->info['total'] < MODULE_SHIPPING_FREEOPTIONS_TOTAL_MIN) && (substr_count($_SESSION['shipping']['id'], 'freeoptions') !=0)) { // Stop checkout if below the minimum and free options is displayed (Note that at this point of execution, the gift certificate is not a factor because if it "helped" then this code is not reached).
        
    echo '<div style="border: 3px solid #777777; padding: 10px 0;"><p style="text-align: center;"><strong>Your order no longer qualifies for Free Shipping.</strong></p>';  
        
      } else { 
    // standard checkout, basically total is anything that doesn't cause freeoptions to display.
    ?> 
    <!-- eof disable checkout button from displaying 2 of 2 -->

    <!--bof submit block -->
      <div id="checkoutOneSubmit" class="buttonRow forward">
        <span id="opc-order-confirm"><?php echo zen_image_button(BUTTON_IMAGE_CHECKOUT_ONE_CONFIRMBUTTON_CHECKOUT_ONE_CONFIRM_ALT); ?></span>
        <span id="opc-order-review"><?php echo zen_image_button(BUTTON_IMAGE_CHECKOUT_ONE_REVIEWBUTTON_CHECKOUT_ONE_REVIEW_ALT); ?></span>
        <?php echo zen_draw_hidden_field('order_confirmed''1''id="confirm-the-order"') . zen_draw_hidden_field ('current_order_total''0''id="current-order-total"'); ?>
      </div>
    <?php
        
    if (!empty($order->customer['email_address'])) {
    ?>
      <div id="checkoutOneEmail" class="forward clearRight"><?php echo sprintf(TEXT_CONFIRMATION_EMAILS_SENT_TO$order->customer['email_address']); ?></div>
    <?php
        
    }
    ?>
      <div class="clearBoth"></div>
    <!--eof submit block -->

    //<!-- bof disable checkout button from displaying 3 of 3 -->
    <?php
    }

    }

  9. #2329
    Join Date
    Apr 2019
    Posts
    245
    Plugin Contributions
    0

    Default Re: One-Page Checkout [Support Thread]

    I need some help to modify the display showing the billing address and shipping address. By OPC default, billing shows on the top and billing (if different than shipping) shows on the bottom. I want to display shipping on the top and billing on the bottom. We are selling physical products so we want the shipping address on the top. I did some tests, and I narrow down this function into following three php files:

    \includes\templates\template_default\templates

    tpl_checkout_one_default.php, tpl_modules_opc_billing_address.php and tpl_modules_opc_shipping_address.php

    tpl_checkout_one_default.php file is very clear. It has two sections, one for billing and one for shipping. Just swap two sections.

    The part I'm not sure is the location for the question "Shipping Address, Same as Billing". By default, this question is between the billing block and shipping block. After I changed the tpl_checkout_one_default.php, this question is above the "Billing/Shipping Address" section. I prefer to move it below this section instead, like the original OPC location, or the bottom of both address blocks.

    I found the following code is located on the top of tpl_modules_opc_shipping_address.php and I suspected they are for this question. So I tried to move this section to the bottom of tpl_modules_opc_billing_address.php. It seems partially work. If I turn this question on/off for several times, or under some special patterns, the billing address block cannot be hidden anymore, unless I refreshed the whole page. So this display/hide function might use JavaScript, which I'm not familiar...

    PHP Code:
    if ($is_virtual_order) {
        echo zen_draw_checkbox_field('shipping_billing', '1', false, 'id="shipping_billing" style="display: none;"');
    } else {
        if (CHECKOUT_ONE_ENABLE_SHIPPING_BILLING == 'false') {
            echo zen_draw_checkbox_field('shipping_billing', '1', false, 'id="shipping_billing" style="display: none;"');
        } else {
    ?>
        <div id="checkoutOneShippingFlag" class="custom-control custom-checkbox" style="display: none;"><?php echo  zen_draw_checkbox_field('shipping_billing''1'$shipping_billing'id="shipping_billing"');?>
          <label class="custom-control-label checkboxLabel" for="shipping_billing"><?php echo TEXT_USE_BILLING_FOR_SHIPPING?></label>
        </div>
    <?php
        
    }
    ?>
    Any help are appreciated.

  10. #2330
    Join Date
    Sep 2008
    Location
    Cleethorpes
    Posts
    1,227
    Plugin Contributions
    6

    Default Re: One-Page Checkout [Support Thread]

    I am getting complaints from customers saying that the greyed out screen lags and takes ages to process a payment. This is through paypal and square up. Because there is a long delay, this confuses the customer. They are thinking that the payment isn't processing and the website has crashed. The greyed out screen is just grey and doesn't let the customers know that their payment is actually processing. It just stays grey for ages. I can't actually say whether people are clicking off this screen or not, but my orders have gone down since installing OPC so I suspect that customers are getting that far and thinking that nothing is happening.

    I am running OPC 2.4.1 on Zen Cart 1.5.7D.
    Nick Smith - Venture Design and Print
    https://venturedesignandprint.co.uk

 

 

Similar Threads

  1. Set number of products displayed per page (support thread)
    By yellow1912 in forum All Other Contributions/Addons
    Replies: 146
    Last Post: 2 Nov 2023, 12:50 AM
  2. v151 Banners In Main Page - Support Thread
    By stevesh in forum Templates, Stylesheets, Page Layout
    Replies: 2
    Last Post: 18 Sep 2021, 03:36 PM
  3. v151 Site Map/Page Not Found: Combined [Support Thread]
    By lat9 in forum All Other Contributions/Addons
    Replies: 7
    Last Post: 4 Jan 2016, 02:19 PM
  4. v151 PayPal Express Checkout Using NVP 84.0 [Support Thread]
    By lat9 in forum Addon Payment Modules
    Replies: 32
    Last Post: 28 Dec 2015, 04:54 PM
  5. Checkout Amazon Style -- Support Thread
    By CJPinder in forum All Other Contributions/Addons
    Replies: 72
    Last Post: 13 Apr 2011, 08:18 PM

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