Bootstrap-4 Template for Zen Cart v1.5.7 and later
Version 3.1.5, by lat9, drbyte, scottcwilson, marco-pm and dennisns7d
Current Support Thread at Zen Cart Forums: https://www.zen-cart.com/showthread.php?223910-ZCA-Bootstrap-4-Template-Support-Thread
Zen Cart Download Link: https://www.zen-cart.com/downloads.php?do=file&id=2191
GitHub repository: https://github.com/lat9/ZCA-Bootstrap-Template.
What it does
This template uses Bootstrap-4 to provide its styling and builds on the base that Raymond Barbour provided over the past few years, supporting Zen Cart versions 1.5.7 and later — best supported by zc157c and later. If your store is based on either zc157, zc157a or zc157b, be sure that you have applied all the patches!
Bootstrap Template, Files List
The following files are provided in the current template distribution:
- /includes/auto_loaders/config.zca_bootstrap.php
- /includes/classes/observers/ZcaBootstrapObserver.php
- /includes/classes/zca/zca_message_stack.php
- /includes/classes/zca/zca_split_page_result.php
- /includes/classes/zca/zca_site_map.php
- /includes/functions/zca_bootstrap_functions.php
- /includes/init_includes/init_zca_bootstrap.php
- /includes/languages/english/bootstrap/extra_definitions/*.php
- /includes/modules/bootstrap/*.php
- /includes/modules/bootstrap/centerboxes/*.php
- /includes/modules/order_total/ot_coupon.php
- /includes/modules/pages/account_history/header_php_account_history_zca_bootstrap.php
- /includes/modules/pages/featured_products/header_php_featured_products_zca_bootstrap.php
- /includes/modules/pages/page_not_found/header_php_page_not_found_zca_bootstrap.php
- /includes/modules/pages/product_reviews/header_php_product_reviews_zca_bootstrap.php
- /includes/modules/pages/product_reviews_info/header_php_product_reviews_info_zca_bootstrap.php
- /includes/modules/pages/product_reviews_write/header_php_product_reviews_write_zca_bootstrap.php
- /includes/modules/pages/products_all/header_php_products_all_zca_bootstrap.php
- /includes/modules/pages/products_new/header_php_products_new_zca_bootstrap.php
- /includes/modules/pages/shopping_cart/header_php_shopping_cart_zca_bootstrap.php
- /includes/modules/pages/site_map/header_php_site_map_zca_bootstrap.php
- /includes/modules/pages/specials/header_php_specials_zca_bootstrap.php
- /includes/modules/sideboxes/bootstrap/*.php
- /includes/templates/bootstrap/*.*
Upgrading from v2.0.0c
As an aid in upgrading from the template's v2.0.0c release, this section identifies the files added, removed or moved in the transition from v2.0.0c of the template to v3.0.0. They might also apply to upgrades from a previous version, but you'll need to check the CHANGELOG.txt
file provided by this template's zip-file for those prior changes.
Files Removed
- /includes/classes/order.php (Removed from this distribution only. Use the zc157b version of the file.)
- /includes/classes/site_map.php (Removed from this distribution only. Use the zc157b version of the file.)
- /includes/classes/ajax/zcAjaxPayment.php (Removed from this distribution only. Use the zc157b version of the file.)
- /includes/classes/zca/zca_breadcrumb.php
- /includes/classes/zca_photoswipe/autoload_default.php
- /includes/classes/zca_photoswipe/jquery_photoswipe.php
- /includes/functions/extra_functions/zen_photoswipe.php
- /includes/init_includes/init_zca_listing_style.php
- /includes/languages/english/bootstrap/button_names.php
- /includes/languages/english/bootstrap/checkout_payment_address.php
- /includes/languages/english/bootstrap/checkout_shipping_address.php
- /includes/languages/english/bootstrap/create_account.php
- /includes/languages/english/bootstrap/create_account_success.php
- /includes/languages/english/bootstrap/document_general_info.php
- /includes/languages/english/bootstrap/document_product_info.php
- /includes/languages/english/bootstrap/featured_products.php
- /includes/languages/english/bootstrap/info_shopping_cart.php
- /includes/languages/english/bootstrap/login.php
- /includes/languages/english/bootstrap/popup_coupon_help.php
- /includes/languages/english/bootstrap/popup_cvv_help.php
- /includes/languages/english/bootstrap/popup_search_help.php
- /includes/languages/english/bootstrap/products_all.php
- /includes/languages/english/bootstrap/products_new.php
- /includes/languages/english/bootstrap/product_free_shipping.php
- /includes/languages/english/bootstrap/product_free_shipping_info.php
- /includes/languages/english/bootstrap/product_info.php
- /includes/languages/english/bootstrap/product_music_info.php
- /includes/languages/english/bootstrap/product_reviews_info.php
- /includes/languages/english/bootstrap/product_reviews_write.php
- /includes/languages/english/bootstrap/shopping_cart.php
- /includes/languages/english/bootstrap/specials.php
- /includes/languages/english/extra_definitions/zca_photoswipe.php
- /includes/modules/order_total/ot_gv.php (Removed from this distribution only. Use the zc157b version of the file.)
- /includes/modules/bootstrap/additional_images.php
- /includes/modules/bootstrap/bootstrap_main_image.php
- /includes/modules/pages/address_book_process/jscript_addr_pulldowns_zca_bootstrap.php
- /includes/modules/pages/checkout_payment_address/jscript_addr_pulldowns_zca_bootstrap.php
- /includes/modules/pages/checkout_shipping_address/jscript_addr_pulldowns_zca_bootstrap.php
- /includes/modules/pages/create_account/jscript_addr_pulldowns_zca_bootstrap.php
- /includes/modules/pages/document_general_info/jscript_zca_photoswipe.php
- /includes/modules/pages/document_product_info/jscript_zca_photoswipe.php
- /includes/modules/pages/login/jscript_addr_pulldowns_zca_bootstrap.php
- /includes/modules/pages/page/jscript_zca_photoswipe.php
- /includes/modules/pages/popup_shipping_estimator/jscript_addr_pulldowns_zca_bootstrap.php
- /includes/modules/pages/product_free_shipping_info/jscript_zca_photoswipe.php
- /includes/modules/pages/product_info/jscript_zca_photoswipe.php
- /includes/modules/pages/product_music_info/jscript_zca_photoswipe.php
- /includes/modules/pages/product_reviews/jscript_zca_photoswipe.php
- /includes/modules/pages/product_reviews_info/jscript_zca_photoswipe.php
- /includes/modules/pages/product_reviews_write/jscript_zca_photoswipe.php
- /includes/modules/pages/specials/main_template_vars.php (Removed from this distribution only. Use the zc157b version of the file.)
- /includes/templates/bootstrap/template_readme.html
- /includes/templates/bootstrap/css/stylesheet_photoswipe.css
- /includes/templates/bootstrap/jscript/jscript_zca_bootstrap.php
- /includes/templates/bootstrap/sideboxes/tpl_banner_box.php
- /includes/templates/bootstrap/sideboxes/tpl_banner_box_all.php
- /includes/templates/bootstrap/sideboxes/tpl_banner_box2.php
- /includes/templates/bootstrap/sideboxes/tpl_currencies.php
- /includes/templates/bootstrap/sideboxes/tpl_languages.php
- /includes/templates/bootstrap/sideboxes/tpl_manufacturer_info.php
- /includes/templates/bootstrap/sideboxes/tpl_music_genres_select.php
- /includes/templates/bootstrap/sideboxes/tpl_no_notifications.php
- /includes/templates/bootstrap/sideboxes/tpl_record_company_select.php
- /includes/templates/bootstrap/sideboxes/tpl_reviews_none.php
- /includes/templates/bootstrap/sideboxes/tpl_reviews_write.php
- /includes/templates/bootstrap/sideboxes/tpl_whos_online.php
- /includes/templates/bootstrap/sideboxes/tpl_yes_notifications.php
- /includes/templates/bootstrap/templates/tpl_modules_checkout_new_address.php
- /includes/templates/bootstrap/templates/tpl_modules_new_payment_address.php
- /includes/templates/bootstrap/templates/tpl_modules_new_shipping_address.php
- /includes/templates/bootstrap/templates/tpl_zc_install_suggested_default.php
Files Added
- /includes/classes/zca/zca_site_map.php
- /includes/languages/english/extra_definitions/bootstrap/zca_bootstrap_common.php
- /includes/modules/pages/page_not_found/header_php_page_not_found_zca_bootstrap.php
- /includes/templates/bootstrap/common/tpl_tabular_display.php
- /includes/templates/bootstrap/jscript/jscript_addr_pulldowns_zca_bootstrap.php
- /includes/templates/bootstrap/jscript/jscript_zca_bootstrap.js
- /includes/templates/bootstrap/templates/tpl_ask_a_question_default.php
- /includes/templates/bootstrap/templates/tpl_modules_common_address_format.php
Files Moved
- /includes/modules/centerboxes/*.* moved to /includes/modules/bootstrap/centerboxes/*.*
Initial Installation
This template currently has one core-file overwrite; you should always backup your cart's database and files prior to making any changes.
- Unzip the template's package file, which you've most likely already done if you're reading this!
- If you haven't made any changes to the Zen Cart 'base' version of
/includes/modules/order_total/ot_coupon.php
, you can simply copy that file from the template's distribution. Otherwise, you'll need to merge the one marked section with your store's version of the file.
- Rename the distribution's
YOUR_ADMIN
sub-directory to match the name of your site's Zen Cart admin directory.
- Copy the files present in the
includes
and the renamed YOUR_ADMIN
sub-directories to your site's file-system.
- Log into your Zen Cart admin to allow the template's initialization to be run. If you want to enable the template:
- Navigate to Tools :: Template Selection to choose the bootstrap template as your site's current template.
- Navigate to Tools :: Layout Boxes Controller to enable and position the sideboxes for your site's use.
As a suggestion, keep the as-distributed bootstrap
template's files unmodified so that you can easily revert to see if your custom changes have affected the template's output. Once you have installed the template and customized its sidebox use, you can clone the template for use on your site.
Version History
This section identifies the template's version history and changes, starting with its v2.0.0c release. Prior version changes can be found in the root of the template's distribution zip-file (CHANGELOG.txt
).
- v3.1.5, 2021-09-21 (lat9/marco-pm)
- BUGFIX: Adding
alt=
tag to additional images.
- BUGFIX: Adding language-translation for Back to Top button's
title=
tag.
- BUGFIX: Adding aria-label and -title to shopping-cart buttons.
- BUGFIX: Correct form-start tag placement to correct invalid HTML on
checkout_confirmation
.
- BUGFIX: Correct data-overflow on
account
page's Previous Orders.
- BUGFIX: Correct PHP notices issued when left/right columns are fully disabled.
- BUGFIX: Enable integration with attribute image-swapper plugins.
- The following files were changed:
- /includes/classes/observers/ZcaBootstrapObserver.php
- /includes/languages/english/extra_definitions/bootstrap/zca_bootstrap_common.php
- /includes/modules/pages/shopping_cart/header_php_shopping_cart_zca_bootstrap.php
- /includes/templates/bootstrap/template_info.php
- /includes/templates/bootstrap/common/tpl_main_page.php
- /includes/templates/bootstrap/modalboxes/tpl_image.php
- /includes/templates/bootstrap/templates/tpl_account_default.php
- /includes/templates/bootstrap/templates/tpl_checkout_confirmation_default.php
- /includes/templates/bootstrap/templates/tpl_modules_main_product_image.php
- /includes/templates/bootstrap/templates/tpl_shopping_cart_default.php
- v3.1.4, 2021-08-19 (lat9/marco-pm)
- BUGFIX: Remove redundant code from
tpl_specials_default.php
.
- BUGFIX: Apply ARIA attribute to previous page-link (split-page-results).
- BUGFIX: Back-to-top link covers checkout-confirmation (and other) buttons.
- BUGFIX: Correct products' quantity min/max/unit display on the product-information pages.
- BUGFIX: Correct duplicate
id=
attributes on centerboxes' display.
- BUGFIX: Adding
.forward
and .back
styling to stylesheet.
- The following files were changed:
- /includes/classes/zca/zca_split_page_results.php
- /includes/modules/bootstrap/centerboxes/featured_products.php
- /includes/modules/bootstrap/centerboxes/specials_index.php
- /includes/templates/bootstrap/template_info.php
- /includes/templates/bootstrap/css/stylesheet.css
- /includes/templates/bootstrap/templates/tpl_document_general_info_display.php
- /includes/templates/bootstrap/templates/tpl_document_product_info_display.php
- /includes/templates/bootstrap/templates/tpl_product_free_shipping_info_display.php
- /includes/templates/bootstrap/templates/tpl_product_info_display.php
- /includes/templates/bootstrap/templates/tpl_product_music_info_display.php
- /includes/templates/bootstrap/templates/tpl_specials_default.php
- v3.1.3, 2021-07-08 (lat9/scottcwilson)
- BUGFIX: Remove redundant code from the
product_listing
module.
- BUGFIX: Standardize centerbox image sizes, all now using 'SMALL_IMAGE_WIDTH' and 'SMALL_IMAGE_HEIGHT'.
- BUGFIX: Apply specificity to the address rendering so that browser autofill's will fill in the proper fields.
- BUGFIX: Correcting duplicate sort-orders for color settings added in v3.1.2.
- BUGFIX: Need the
clearBoth
CSS class defined, used by template_default
templates.
- BUGFIX: Shopping-cart display requires horizontal scroll on extra-small screens.
- BUGFIX: "Shopping for ..." message from admin Place Order button doesn't use font-awesome icons.1
- The following files were changed:
- /includes/auto_loaders/config.zca_bootstrap.php1
- /includes/modules/bootstrap/product_listing.php
- /includes/modules/bootstrap/centerboxes/featured_products.php
- /includes/modules/bootstrap/centerboxes/specials_index.php
- /includes/templates/bootstrap/template_info.php
- /includes/templates/bootstrap/css/stylesheet.css
- /includes/templates/bootstrap/templates/tpl_modules_common_address_format.php
- /includes/templates/bootstrap/templates/tpl_modules_create_account.php
- /includes/templates/bootstrap/templates/tpl_shopping_cart_default.php
- /YOUR_ADMIN/includes/init_includes/init_bc_config.php
- 1Note: For this change to be effective for stores running zc157c and earlier, a core-file edit of
/includes/auto_loaders/config.core.php
is required. Find the following section:
/**
* Breakpoint 130.
*
* require('includes/init_includes/init_customer_auth.php');
* messageStack = new messageStack();
*
*/
$autoLoadConfig[130][] = array('autoType'=>'classInstantiate',
'className'=>'messageStack',
'objectName'=>'messageStack');
$autoLoadConfig[130][] = array('autoType'=>'init_script',
'loadFile'=> 'init_customer_auth.php');
and make the highlighted changes:
/**
* Breakpoint 130.
*
* require('includes/init_includes/init_customer_auth.php');
* messageStack = new messageStack();
*
*/
$autoLoadConfig[130][] = array('autoType'=>'classInstantiate',
'className'=>'messageStack',
'objectName'=>'messageStack');
//-bof-bootstrap-v313-Moving load point
$autoLoadConfig[135][] = array('autoType'=>'init_script',
'loadFile'=> 'init_customer_auth.php');
//-eof-bootstrap-v313
- v3.1.2, 2021-06-02 (lat9/torvista)
- BUGFIX: Remove unwanted background color from EZ-Pages' footer links.
- BUGFIX: Correcting header-messages 'hidden' by upper nav-bar and logo displays.
- BUGFIX: Reduce HTML 'footprint' associated with stylesheet_zca_colors.php (reducing number of bytes).
- BUGFIX: Non-product-listing pages redirect to index-page on add-multiple-to-cart action.
- BUGFIX: Correct PHP notice generated on specials and products_new listings.
- BUGFIX: Correct various HTML issues in the admin coloring tool.
- BUGFIX: Add coloring for the product*_info pages' add-to-cart element for the admin coloring tool.
- The following files were changed:
- /includes/modules/bootstrap/product_listing.php
- /includes/modules/pages/products_new/header_php_products_new_zca_bootstrap.php
- /includes/modules/pages/specials/header_php_specials_zca_bootstrap.php
- /includes/templates/bootstrap/template_info.php
- /includes/templates/bootstrap/common/tpl_header.php
- /includes/templates/bootstrap/css/stylesheet_colors.css
- /includes/templates/bootstrap/css/stylesheet_zca_colors.php
- /YOUR_ADMIN/zca_bootstrap_colors.php
- /YOUR_ADMIN/includes/init_includes/init_bc_config.php
- v3.1.1, 2021-02-14 (lat9)
- BUGFIX: Correct shipping-estimator display when using dropdown states.
- The following files were changed or added:
- /includes/modules/bootstrap/shipping_estimator.php
- /includes/templates/bootstrap/template_info.php
- /includes/templates/bootstrap/templates/tpl_modules_shipping_estimator.php
- v3.1.0, 2021-02-01 (lat9/drbyte/dennisns7d)
- BUGFIX: Correct PHP notice when a payment method doesn't return 'fields'.
- BUGFIX: Correct duplicate classes created for CSS buttons.
- CHANGE: Use 'font-awesome' stars for various product rating indicators.
- BUGFIX: Correct missing language constants on SNAF pages.
- CHANGE: Various mobile layout improvements.
- BUGFIX: Set scrollable area on mobile menu.
- CHANGE: 'Sync' template files, using zc157b as the change-basis.
- BUGFIX: Correct various HTML validation issues.
- BUGFIX: Correct colors applied to the navigation menus; base/hover colors were reversed.
- BUGFIX: Apply bootstrap classes to module-based displays in checkout pages.
- BUGFIX: Correct PHP notices issued for the 'Also Purchased Products' centerbox.
- BUGFIX: Clarify description of category-tab's hover color.
- CHANGE: Update
Tools :: ZCA Bootstrap Colors
, enabling import/export via .csv.
- BUGFIX: Shipping Estimator pop-up doesn't change zones when the country is changed; change to a modal.
- CHANGE: Updating the Bootstrap base to v4.6.0 from v4.5.3.
- CHANGE: Reuse information-sidebox for the offcanvas menu, including only if the base sidebox is enabled via the Layout Boxes Controller.
- CHANGE: Update order-totals display to accept a column-count.
- The following files were changed:
- /includes/classes/observers/ZcaBootstrapObserver.php
- /includes/functions/zca_bootstrap_functions.php
- /includes/languages/english/extra_definitions/bootstrap/zca_bootstrap_common.php
- /includes/modules/bootstrap/attributes.php
- /includes/modules/bootstrap/category_row.php
- /includes/modules/bootstrap/product_listing.php
- /includes/modules/bootstrap/centerboxes/also_purchased_products.php
- /includes/modules/bootstrap/centerboxes/featured_products.php
- /includes/modules/sideboxes/bootstrap/information.php
- /includes/modules/sideboxes/bootstrap/search.php
- /includes/templates/bootstrap/template_info.php
- /includes/templates/bootstrap/common/html_header.php
- /includes/templates/bootstrap/common/tpl_columnar_display.php
- /includes/templates/bootstrap/common/tpl_main_page.php
- /includes/templates/bootstrap/common/tpl_offcanvas_menu.php
- /includes/templates/bootstrap/common/tpl_tabular_display.php
- /includes/templates/bootstrap/css/stylesheet.css
- /includes/templates/bootstrap/css/stylesheet_colors.css
- /includes/templates/bootstrap/css/stylesheet_zca_colors.php
- /includes/templates/bootstrap/jscript/jscript_addr_pulldowns_zca_bootstrap.php
- /includes/templates/bootstrap/modalboxes/tpl_shipping_estimator.php
- /includes/templates/bootstrap/sideboxes/tpl_reviews_random.php
- /includes/templates/bootstrap/templates/tpl_address_book_default.php
- /includes/templates/bootstrap/templates/tpl_ajax_checkout_confirmation_default.php
- /includes/templates/bootstrap/templates/tpl_checkout_confirmation_default.php
- /includes/templates/bootstrap/templates/tpl_checkout_payment_default.php
- /includes/templates/bootstrap/templates/tpl_checkout_shipping_default.php
- /includes/templates/bootstrap/templates/tpl_document_general_info_display.php
- /includes/templates/bootstrap/templates/tpl_modules_order_totals.php
- /includes/templates/bootstrap/templates/tpl_modules_product_listing.php
- /includes/templates/bootstrap/templates/tpl_modules_shipping_estimator.php
- /includes/templates/bootstrap/templates/tpl_product_reviews_default.php
- /includes/templates/bootstrap/templates/tpl_product_reviews_info_default.php
- /includes/templates/bootstrap/templates/tpl_product_reviews_write_default.php
- /includes/templates/bootstrap/templates/tpl_reviews_default.php
- /includes/templates/bootstrap/templates/tpl_shopping_cart_default.php
- /includes/templates/bootstrap/templates/tpl_specials_default.php
- /YOUR_ADMIN/zca_bootstrap_colors.php
- /YOUR_ADMIN/includes/init_includes/init_bc_config.php
- /YOUR_ADMIN/includes/languages/english/zca_bootstrap_colors.php
- v3.0.0, 2020-11-26 (lat9/drbyte)
- BUGFIX: Correct various PHP notices, deprecations and warnings.
- CHANGE: Use zc157b version of
/includes/modules/order_total/ot_coupon.php
as the change-basis.
- CHANGE: Remove
/includes/classes/ajax/zcAjaxPayment.php
from this distribution, no change needed.
- CHANGE: "Rename" the template's
jscript_zca_bootstrap.php
to use a .js
extension, so it's cacheable.
- CHANGE: Use the zc157+ version of the
breadcrumb.php
class; no longer a core-file overwrite.
- CHANGE: Restore the use of a common-format address-block.
- CHANGE: Remove
/includes/classes/order.php
from this distribution; using the zc157+ version.
- CHANGE: Update jQuery to v3.5.1 and don't use
document.write
.
- CHANGE: Override only the messageStack's
add
function (future-proofing).
- CHANGE: Enable a store to control the justification for the order-totals' section on various pages.
- CHANGE: Remove
/includes/modules/order_total/ot_gv.php
from this distribution; using the zc157+ version.
- CHANGE: Use the
template_default
version of jscript_framework.php
(future-proofing).
- CHANGE: Incorporate the zc157+
ask_a_question
page's formatting.
- CHANGE: Reduce language-related template overrides.
- CHANGE: Don't display Model block if no model is supplied.
- CHANGE:
DISPLAY_PAGE_PARSE_TIME
setting removed in zc157+.
- CHANGE: Reduce sidebox-related template overrides.
- CHANGE: Ensure that
zca_bootstrap_active
is present prior to calling.
- CHANGE:
specials
page SQL, products_description
is keyed on both products_id and language_id.
- BUGFIX: Correct PHP deprecated log in product listings.
- BUGFIX: Correct PHP warning for specials' centerbox.
- BUGFIX: Correct missing prev/next icons in image-carousel display.
- CHANGE: Remove core-file overwrite requirement for the
specials
page.
- CHANGE: Remove core-file overwrite requirement for the
site_map.php
class.
- CHANGE: Remove the ZCA Photoswipe feature as it's no longer supported by its author.
- BUGFIX: Correct HTML validation issues on products*_info pages.
- CHANGE: Products' notification centerboxes, interoperability with guest-checkout.
- CHANGE: Update font-awesome support to 5.15.1, using the minified version with integrity.
- CHANGE: Update bootstrap support to 4.5.3 (bundled).
- For this release, continue as if all files in the distribution have changed!