Jump to content

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

How To Post Code On All Pages Except On Order Confirmation Page Rate Topic   - - - - -

 
  • cool999
  • Senior Member
  • Trial users
  • Join Date: 26-Jul 12
  • 269 posts

Posted 07 January 2016 - 06:48 AM #1

<script type='text/javascript'>
var _xxx=_xxx||{};_xxx.apiKey='xxxxxxxxxxxxxxxxxxxxxx';
(function(){var ref=document.createElement('script');ref.type='text/javascript';ref.async=true;ref.src='https://cdn.xxx.com/libs/xxx.min.js';var s=document.getElementsByTagName('script')[0];s.parentNode.insertBefore(ref,s);})();
</script>

I want to put this code on all pages except the order confirmation page. How can I do this?

Please help



 

Posted 07 January 2016 - 06:59 AM #2

before this code check if controller is not checkout and mode is not complete.

 

 

==========================================================

{if {$runtime.controller} != checkout && {$runtime.mode} != complete}
      {paste you code here!!}

{/if}

==========================================================

 

put this code in index.post.tpl



 
  • cool999
  • Senior Member
  • Trial users
  • Join Date: 26-Jul 12
  • 269 posts

Posted 07 January 2016 - 07:13 AM #3

I am using cs-cart v4



 
  • cool999
  • Senior Member
  • Trial users
  • Join Date: 26-Jul 12
  • 269 posts

Posted 07 January 2016 - 08:17 AM #4

Please explain anyone???



 
  • tbirnseth
  • CS Cart Expert
  • Authorized Reseller
  • Join Date: 08-Nov 08
  • 11429 posts

Posted 07 January 2016 - 11:41 PM #5

What would you like explained?

@himanshudangwal response is correct (with exception that you probably want to use literal tags around the code since it contains {}'s to be safe)


EZ Merchant Solutions: Custom (USA based) B2B Development, Consulting, Development and Special Projects (get a quote here).
Commercial addons, payment methods and modifications to meet your business and operations needs.


 
  • cool999
  • Senior Member
  • Trial users
  • Join Date: 26-Jul 12
  • 269 posts

Posted 08 January 2016 - 07:13 AM #6

this has been done and working. Thanks guys. I have created a file footer.post.tpl