Results 1 to 4 of 4
  1. #1
    Join Date
    Oct 2012
    Posts
    282
    Plugin Contributions
    0

    Default Javascript not loading on Checkout pages

    Hey everyone,
    I've put a jQuery file in the includes/templates/myTemplate/jscript/jquery

    it loads on the homepage, product pages but on some of the checkout and shopping cart pages it does not load.

    any advice on how to track down this problem?

    if i open up tpl_shoppingcart for example, what php function might i look for that might be missing?

    thanks in advance

    very aggravating, i can add manually to headers but i like to know why something isn't working before i do that
    Last edited by tcarden; 21 Mar 2014 at 08:59 PM.

  2. #2
    Join Date
    Jan 2004
    Posts
    66,374
    Blog Entries
    7
    Plugin Contributions
    274

    Default Re: Javascript not loading on Checkout pages

    Quote Originally Posted by tcarden View Post
    if i open up tpl_shoppingcart for example, what php function might i look for that might be missing?
    None. The tpl_anything files have nothing to do with autoloading in the jscript folder.

    What's the URL? Which script is supposed to be loading?
    .

    Zen Cart - putting the dream of business ownership within reach of anyone!
    Donate to: DrByte directly or to the Zen Cart team as a whole

    Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
    Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

  3. #3
    Join Date
    Oct 2012
    Posts
    282
    Plugin Contributions
    0

    Default Re: Javascript not loading on Checkout pages

    oh hey Dr. Byte. belated thanks.

    the site home page, where the file is loading correctly is
    http://www.mscanvashouse.info/kart/

    where the file is not loading, shopping-cart and check out pages, is here
    http://www.mscanvashouse.info/kart/i...=shopping_cart

    you can tell by this, when scrolling the page, the cart follows the page scroll

    the file that should be loading is
    <script type="text/javascript" src="/kart/includes/templates/Ms/jscript/jquery/jquery-1.10.2.min.js"></script>

    thanks for looking

  4. #4
    Join Date
    Jan 2004
    Posts
    66,374
    Blog Entries
    7
    Plugin Contributions
    274

    Default Re: Javascript not loading on Checkout pages

    In ZC v1.5.x and lower, files named like this will not auto-load:
    /includes/templates/Ms/jscript/jquery/jquery-1.10.2.min.js

    For javascript, it only automatically loads files in the following patterns:
    /includes/templates/Ms/jscript/jscript*.php
    /includes/templates/Ms/jscript/jscript*.js
    /includes/modules/pages/PAGE_NAME/jscript*.php
    /includes/modules/pages/PAGE_NAME/jscript*.js

    So, I suspect you've got a jscriptXXXXXX.php file in one of those places (probably in includes/modules/pages/index/jscriptXXXXXX.php) that's got some code in it to output the code that loads the jquery stuff.
    If it's in the pages/index/ folder then you could probably copy that file to the pages/shopping_cart/ folder to trigger it to load there too.
    There are several ways to do it. It will help to know how you're currently doing it.
    .

    Zen Cart - putting the dream of business ownership within reach of anyone!
    Donate to: DrByte directly or to the Zen Cart team as a whole

    Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
    Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

 

 

Similar Threads

  1. v154 EZ pages not loading
    By jcrewe in forum General Questions
    Replies: 7
    Last Post: 3 Mar 2015, 04:00 PM
  2. Replies: 9
    Last Post: 19 Apr 2012, 05:56 PM
  3. adding javascript framework to login/checkout pages
    By Minnie Mouse in forum General Questions
    Replies: 4
    Last Post: 9 Feb 2007, 12:55 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