---
title: Front-end Integration
slug: extensions/HRm5GKa7TNg6rEAMq1k23
docTags: 
createdAt: 2025-12-14T14:23:41.918Z
---

# JavaScript Integration

The full JS snippet for both production and sandbox environments can be found
[here](https://portal.forter.com/app/integration/js-snippets)

The Forter JavaScript Snippet should be injected into the site footer section for all web pages. The following site template has been built:

`int_forter/cartridge/templates/default/custom/fortersnippetjs.isml`

When you add your **Site Id** and **Secret Key** to your cartridge settings, this `.isml` template will be configured. Please let your Forter onboarding team know once this has been added, so that they can complete the enablement remotely.

# MFRA JavaScript

### Include the Forter JavaScript snippet

The Forter JavaScript Snippet should be injected into the `checkout.isml` and `page.isml` templates in your existing **app\_storefront\_base**. The instructions and code snippets are included below:

## 1) Update the checkout.isml template

Update the `checkout.isml` template with the forterJS snippet. The exact path in the Forter SFCC cartridge is:
`int_forter_mfra/cartridge/templates/default/common/layout/checkout.isml`.

This extends the `app_storefront_base/cartridge/templates/default/common/layout/checkout.isml` template with:

```html
<isinclude template="custom/fortersnippetjs"/>
```

The full **checkout.isml** file is included below:

:::ExpandableHeading
### Full checkout.isml template

```html
<iscontent type="text/html" charset="UTF-8" compact="true"/>

<isinclude template="/components/modules" sf-toolkit="off" />

<!DOCTYPE html>
<html lang="en">
    <head>
        <isinclude template="/common/htmlHead" />
        <isactivedatahead/>
    </head>
    <body>
        <div class="page">
            <isinclude template="/components/header/pageHeaderNomenu" />
            <isreplace/>
            <isinclude template="/components/footer/pageFooter" />
        </div>
        <isinclude template="/common/scripts" />
<-- add the below line of code --/>
        <isinclude template="custom/fortersnippetjs"/>
<-- end --/>
        <isinclude url="${URLUtils.url('ConsentTracking-Check')}"/>
    </body>
</html>
```
:::

## 2) Update the page.isml template

You should include the `page.isml` template with the forterJS snippet. The exact path in the Forter SFCC cartridge is:
`int_forter_mfra/cartridge/templates/default/common/layout/page.isml`.

This extends the `app_storefront_base /cartridge/templates/default/common/layout/page.isml` html template with the following code:

```html
<isinclude template="custom/fortersnippetjs"/>
```

The full **page.isml** file is included below:

:::ExpandableHeading
### Full page.isml file

```html
<iscontent type="text/html" charset="UTF-8" compact="true"/>

<isinclude template="/components/modules" sf-toolkit="off" />

<!DOCTYPE html>
<html lang="en">
    <head>
        <isinclude template="/common/htmlHead" />
        <isactivedatahead/>
    </head>
    <body>
        <div class="page" data-action="${pdict.action}" data-querystring="${pdict.queryString}" >
            <isinclude template="/components/header/pageHeader" />
            <isreplace/>
            <isinclude template="/components/footer/pageFooter" />
        </div>
        <div class="error-messaging"></div>
        <div class="modal-background"></div>
        <iscontentasset aid="cookie_hint" />
        <isinclude template="/common/scripts" />
        <isinclude template="custom/fortersnippetjs"/>
        <isinclude url="${URLUtils.url('ConsentTracking-Check')}"/>
    </body>
</html>
```
:::
