Jump to content

  • You cannot start a new topic
  • You cannot reply to this topic

Relocating Submit My Order Button In Checkout Rate Topic   - - - - -

 
  • Mongoose
  • Senior Member
  • Members
  • Join Date: 08-Mar 13
  • 798 posts

Posted 14 November 2017 - 11:55 AM #1

I would like move up the SUBMIT MY ORDER button on my Checkout page.

See screenshot below

 

submitmyorderbutton.png

 

What part of the code and which file should I change ?


two V4.6.2 and one  V4.2.4 - hedonist working on Sundays


 
  • eComLabs
  • CS-Cart Expert
  • Authorized Reseller
  • Join Date: 27-Jan 14
  • 15,479 posts

Posted 14 November 2017 - 01:30 PM #2

design/themes/THEME/templates/views/checkout/components/final_section.tpl


GET A FREE QUOTE | CS-Cart Add-ons | CS-Cart Licenses | CS-Cart Development | CS-Cart Design | Server Configuration

Certified CS-Cart RU Developer | Сертифицированный разработчик на CS-Cart Русская Версия

 
  • Mongoose
  • Senior Member
  • Members
  • Join Date: 08-Mar 13
  • 798 posts

Posted 14 November 2017 - 01:47 PM #3

Thanks so much.

PS did you guys not have an addon that allows you to pull content from a page and put that content into a block ?


two V4.6.2 and one  V4.2.4 - hedonist working on Sundays


 
  • Mongoose
  • Senior Member
  • Members
  • Join Date: 08-Mar 13
  • 798 posts

Posted 14 November 2017 - 02:01 PM #4

design/themes/THEME/templates/views/checkout/components/final_section.tpl

 

I have digging in the file final_section.tpl and see this line of code:

{$show_place_order = false}

{if $cart|fn_allow_place_order:$auth}
    {$show_place_order = true}
{/if}

{if $recalculate && !$cart.amount_failed}
    {$show_place_order = true}
{/if}

{if $show_place_order}

    <div class="clearfix {if !$is_payment_step} checkout__block ty-checkout-block-terms{/if}">
        {hook name="checkout:final_section_customer_notes"}
            {include file="views/checkout/components/customer_notes.tpl"}
        {/hook}
        
        {if !$suffix}
            {assign var="suffix" value=""|uniqid}
        {/if}
        {include file="views/checkout/components/terms_and_conditions.tpl" suffix=$suffix}
    </div>

    <input type="hidden" name="update_steps" value="1" />
    
    {if !$is_payment_step}
        <div class="clearfix">
            <div class="ty-checkout-buttons cm-checkout-place-order-buttons">
                {include file="buttons/place_order.tpl" but_text=__("submit_my_order") but_name="dispatch[checkout.place_order]" but_id="place_order"}
            </div>

            {if $recalculate && $cart.shipping_required}
                <input type="hidden" name="next_step" value="step_two" />
                <div class="ty-checkout-buttons cm-checkout-recalculate-buttons hidden">
                    {include file="buttons/button.tpl" but_meta="ty-btn__secondary cm-checkout-recalculate" but_name="dispatch[checkout.update_steps]" but_text=__("recalculate_shipping_cost")}
                </div>
            {/if}
        </div>
    {/if}

{else}

    {if $cart.shipping_failed}
        <p class="ty-error-text ty-center">{__("text_no_shipping_methods")}</p>
    {/if}

    {if $cart.amount_failed}
        <div class="checkout__block">
            <p class="ty-error-text">{__("text_min_order_amount_required")}&nbsp;<strong>{include file="common/price.tpl" value=$settings.General.min_order_amount}</strong></p>
        </div>
    {/if}

    <div class="ty-checkout-buttons">
        {include file="buttons/continue_shopping.tpl" but_href=$continue_url|fn_url but_role="action"}
    </div>
    
{/if}

I see the line of code between line nr 25 and 31 that you are referring to.
 

 {if !$is_payment_step}
        <div class="clearfix">
            <div class="ty-checkout-buttons cm-checkout-place-order-buttons">
                {include file="buttons/place_order.tpl" but_text=__("submit_my_order") but_name="dispatch[checkout.place_order]" but_id="place_order"}
            </div>

How far up should I move this line of code in this document ?

 


two V4.6.2 and one  V4.2.4 - hedonist working on Sundays


 
  • eComLabs
  • CS-Cart Expert
  • Authorized Reseller
  • Join Date: 27-Jan 14
  • 15,479 posts

Posted 15 November 2017 - 05:46 AM #5

I have digging in the file final_section.tpl and see this line of code:

{$show_place_order = false}

{if $cart|fn_allow_place_order:$auth}
    {$show_place_order = true}
{/if}

{if $recalculate && !$cart.amount_failed}
    {$show_place_order = true}
{/if}

{if $show_place_order}

    <div class="clearfix {if !$is_payment_step} checkout__block ty-checkout-block-terms{/if}">
        {hook name="checkout:final_section_customer_notes"}
            {include file="views/checkout/components/customer_notes.tpl"}
        {/hook}
        
        {if !$suffix}
            {assign var="suffix" value=""|uniqid}
        {/if}
        {include file="views/checkout/components/terms_and_conditions.tpl" suffix=$suffix}
    </div>

    <input type="hidden" name="update_steps" value="1" />
    
    {if !$is_payment_step}
        <div class="clearfix">
            <div class="ty-checkout-buttons cm-checkout-place-order-buttons">
                {include file="buttons/place_order.tpl" but_text=__("submit_my_order") but_name="dispatch[checkout.place_order]" but_id="place_order"}
            </div>

            {if $recalculate && $cart.shipping_required}
                <input type="hidden" name="next_step" value="step_two" />
                <div class="ty-checkout-buttons cm-checkout-recalculate-buttons hidden">
                    {include file="buttons/button.tpl" but_meta="ty-btn__secondary cm-checkout-recalculate" but_name="dispatch[checkout.update_steps]" but_text=__("recalculate_shipping_cost")}
                </div>
            {/if}
        </div>
    {/if}

{else}

    {if $cart.shipping_failed}
        <p class="ty-error-text ty-center">{__("text_no_shipping_methods")}</p>
    {/if}

    {if $cart.amount_failed}
        <div class="checkout__block">
            <p class="ty-error-text">{__("text_min_order_amount_required")}&nbsp;<strong>{include file="common/price.tpl" value=$settings.General.min_order_amount}</strong></p>
        </div>
    {/if}

    <div class="ty-checkout-buttons">
        {include file="buttons/continue_shopping.tpl" but_href=$continue_url|fn_url but_role="action"}
    </div>
    
{/if}

I see the line of code between line nr 25 and 31 that you are referring to.
 

 {if !$is_payment_step}
        <div class="clearfix">
            <div class="ty-checkout-buttons cm-checkout-place-order-buttons">
                {include file="buttons/place_order.tpl" but_text=__("submit_my_order") but_name="dispatch[checkout.place_order]" but_id="place_order"}
            </div>

How far up should I move this line of code in this document ?

 

You should place it before

{include file="views/checkout/components/customer_notes.tpl"}

Thanks so much.

PS did you guys not have an addon that allows you to pull content from a page and put that content into a block ?

 

Sure

 

https://www.ecom-lab...cks-add-on.html


GET A FREE QUOTE | CS-Cart Add-ons | CS-Cart Licenses | CS-Cart Development | CS-Cart Design | Server Configuration

Certified CS-Cart RU Developer | Сертифицированный разработчик на CS-Cart Русская Версия

 
  • Mongoose
  • Senior Member
  • Members
  • Join Date: 08-Mar 13
  • 798 posts

Posted 15 November 2017 - 07:44 PM #6

I tried what you suggested and played around with it but without the desired results.

But let me explain why I was playing with the idea of relocating the SUBMIT MY ORDER button. It is related to other ecommerce platforms that have the finalize my order button closer to the top of the final checkout phase. 

We noticed that many of our customers have the expectation that the finalize my order button is either more closer to the top of the site as seen in this one step checkout sample.

 

See screenshot

 

2017-11-15 20_41_25-One Step Checkout.png

 

 


two V4.6.2 and one  V4.2.4 - hedonist working on Sundays


 
  • eComLabs
  • CS-Cart Expert
  • Authorized Reseller
  • Join Date: 27-Jan 14
  • 15,479 posts

Posted 16 November 2017 - 05:33 AM #7

So did you change the location? What result did you receive?


GET A FREE QUOTE | CS-Cart Add-ons | CS-Cart Licenses | CS-Cart Development | CS-Cart Design | Server Configuration

Certified CS-Cart RU Developer | Сертифицированный разработчик на CS-Cart Русская Версия