Scenario
Some SiteBuilder users are using the Shipping estimator on their web stores shopping cart to provide shoppers an option to estimate the shipping cost on the shopping cart level without going to the entire checkout process and reach the review and submit section.
Solution
Pre-requisite: The shopping estimator should exist in the shopping cart. To verify, navigate to Setup > Site Builder > Set Up Web Site > Appearance tab > Shopping cart section > Show Shipping Estimator in Cart field is checked.
- Navigate to Commerce > Site Builder > Tags > New
- Fields:
a. Tag: set preferred name for the tag (example: CHANGESUBMIT)
b. Click Save - Locate the theme that the user is currently using on the webstore:
a. Navigate to Commerce > Websites > Website List
b. Navigate to the Appearance tab
c. Go to Web Site Templates section
d. Take note of the theme that is associated in the Web Site Theme field
Note: In case user is using the standard Basic Theme, user needs to customize a theme and then associate it on this field. - Navigate to Commerce > Site Builder > Themes,
- Edit the theme noted in Step 3.d.
- Go to the Body tab
- Go to the Footer Template section
- Scroll on the button of the text area field
- Add the Tag created in Step #2
Example: <CHANGESUBMIT> - Navigate to Commerce > Site Builder > Tabs
Note: Make sure that in case user does have a multiple web stores, the filter on the list of tabs is the Web Site where the Theme is associated. - Edit the shopping cart tab
- Navigate to the Tag Substitution tab:
a. Locate the tag created in Step 2. (Example: CHANGESUBMIT )
b. On the Substitution Value place the following code:
<script>
function addLoadEvent(func) { var oldonload = window.onload;
if (typeof window.onload != 'function') { window.onload = func; }
else { window.onload = function() {
if (oldonload) {
oldonload();
}
func();
}
}
}
addLoadEvent(function()
{ document.getElementById('submitter').value='New Submit Button Label';
});
</script>