Disable Bolt for BigCommerce

Disable Bolt Plugin

  1. Log in to Bigcommerce.Β 
  2. Navigate to Store Front > Payments > Online Payment Methods.
  3. Toggle off the Bolt radio button.
  4. Navigate to Store Front > My Themes > Advanced > Edit Theme Files
  5. Comment out the following scripts for each page.html:
    • templates > components > cart > preview.html
    • templates > components > cart > totals.html
    • templates > components > common > cart-preview.html
    • templates > components > products > add-to-cart.html
    • templates > pages > cart.html

Scripts

<!--<script
  id="bolt-connect"
  type="text/javascript"
  src="https://connect.bolt.com/connect-bigcommerce.js"
  data-publishable-key="gQ8isqpsUR6A.Wr413Y6dCpc5.14736a46de3aa31b19c2e603317d68cd340698e21469e452fda30444094c39b9"
  data-shopping-cart-id="BigCommerce">
</script>-->
<!--<script>
    var originalCheckoutButton = document.querySelector(".previewCartCheckout .button.button--primary");
    var boltButtons = document.getElementsByClassName("bolt-button-wrapper");
        for (var i = 0; i < boltButtons.length; i++) {
            boltButtons[i].style.display = 'block';
        }
        originalCheckoutButton.style.display = 'none';
</script>-->
<!--<script>
    var config = { childList: true, subtree: true };
    var totalClassName = "previewCartCheckout-price";
    var totalPrice = "";
    var callback = function(mutationsList) {
        var elms = document.getElementsByClassName(totalClassName);
        if (elms.length == 0) {
            return;
        }
        var newPrice = elms[0].innerHTML;
        if (newPrice !== totalPrice && window.BoltCheckout) {
            window.BoltCheckout.reloadBigCommerceCart();
        }
        totalPrice = newPrice;
    };
    new MutationObserver(callback).observe(document.body, config);
</script>-->

Finally, save and apply all files and Bolt is temporarily disabled. To reenable Bolt, simply uncomment everything.


Disable SSO Commerce

If your team saved a version of your theme that does not include the SSO Commerce buttons, you can simply switch to that version of your theme to remove all SSO Commerce buttons.

1. Replace All Log in and Track My Order buttons

  1. Navigate to your storefront’s theme files.
  2. Make a copy the active theme.
  3. Replace all Bolt login buttons with your original button links:
    • All elements containing <a class="bolt-sso-custom" .. >
    • All elements containing <a class="bolt-account-sso" .. >

2. Remove Scripts

Remove this script from all of your theme files:

    <script>
        var insertAccountScript = function () {
            var scriptTag = document.getElementById('bolt-account');
            if (scriptTag) {
                return;
            }
            scriptTag = document.createElement('script');
            scriptTag.setAttribute('type', 'text/javascript');
            scriptTag.setAttribute('async', '');
            scriptTag.setAttribute('src', '{{bolt-script-url}}');
            scriptTag.setAttribute('id', 'bolt-account');
            scriptTag.setAttribute('data-publishable-key', <insert publishable key>);
            document.head.appendChild(scriptTag);
        }
      
        function insertButtons() {
            if (typeof BoltAccount === 'undefined') {
                window.setTimeout(insertButtons, 100);
                return;
            }
            BoltAccount.injectButtons();
        }

        insertAccountScript();
        insertButtons();
    </script>

3. Replace Login and Create Account Pages

Ensure that the native Login (/login.php) and Create Account (/login.php?action=create_account) pages have their contents replaced with the original BigCommerce pages. Ensure these pages do not contain any Bolt elements.

4. Restore the Addresses, Payment Methods, and Account Details Pages

Restore any pages that you might have disabled as part of SSO onboarding.

πŸ‘Ž

How did we do?

πŸ“–On This Page