Results 1 to 5 of 5
  1. #1
    Join Date
    Jun 2012
    Posts
    289
    Plugin Contributions
    0

    Default Bootstrap, jquery, etc support file downloads

    I would like to download each support file needed for zen cart and addon's and save them in the zen cart file structure somewhere during development. I want to do this so that when I operate with cache off these files are local instead of being downloaded each time I test a CSS change. Where can/should I store these files?
    TIA,
    Dave

  2. #2
    Join Date
    Jan 2004
    Posts
    66,350
    Blog Entries
    7
    Plugin Contributions
    271

    Default Re: Bootstrap, jquery, etc support file downloads

    Your browser already caches those things locally automatically.
    .

    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
    Jun 2012
    Posts
    289
    Plugin Contributions
    0

    Default Re: Bootstrap, jquery, etc support file downloads

    I want to do this so that when I operate with cache off these files are local instead of being downloaded each time I test a CSS change.

  4. #4
    Join Date
    Feb 2006
    Location
    Tampa Bay, Florida
    Posts
    7,857
    Plugin Contributions
    108

    Default Re: Bootstrap, jquery, etc support file downloads

    Unless you are constantly on airplanes or in other places with bad/no WiFi, this is more trouble than it's worth. If you're at home with decent networking, you won't notice a difference.

    But if you want to do it ... I used to do it when I was traveling a lot, and here's how I did it:

    Look at includes/templates/responsive_classic/common/html_header.php and search down to where jQuery is loaded.

    It uses <script ...> to load it, and then does a test to see if it was loaded and if not, loads the one from the local jscript folder.
    Wrap the <script ...> in a check

    if (USE_LOCAL_SCRIPTS) {

    and set that define when you want to use what's in your local environment.

    Repeat for all scripts required.
    That Software Guy. My Store: Zen Cart Modifications
    Available for hire - See my ad in Services
    Plugin Moderator, Documentation Curator, Chief Cook and Bottle-Washer.

  5. #5
    Join Date
    Jan 2004
    Posts
    66,350
    Blog Entries
    7
    Plugin Contributions
    271

    Default Re: Bootstrap, jquery, etc support file downloads

    If you're only working locally during dev time, you can of course also just comment-out the CDN load so that it does load the local one.
    .

    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. v155 ZCA Bootstrap 4 Template [Support Thread]
    By rbarbour in forum Addon Templates
    Replies: 493
    Last Post: 30 Jul 2021, 08:56 PM
  2. v155 File Auto-Versioning (CSS, JS, etc) for Templates [Support Thread]
    By lat9 in forum All Other Contributions/Addons
    Replies: 11
    Last Post: 19 Jul 2017, 08:26 PM
  3. Jquery Zoom [Support thread]
    By yellow1912 in forum All Other Contributions/Addons
    Replies: 384
    Last Post: 11 Dec 2013, 02:41 AM
  4. Jquery Lightbox [Support thread]
    By yellow1912 in forum All Other Contributions/Addons
    Replies: 257
    Last Post: 2 Aug 2012, 10:57 PM
  5. Image rotator in index page- jquery etc
    By ashjam in forum Templates, Stylesheets, Page Layout
    Replies: 3
    Last Post: 9 Feb 2010, 12:09 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